每日踩坑 2019-08-23 button 元素点击后刷新页面

button标签按钮会提交表单。

解决方案:

<button class="btn btn-primary"  type="button" ></i>确定</button>

现在程序最好兼容各个主流浏览器,应始终为按钮规定 type 属性。

https://www.cnblogs.com/fengduandeai/p/8806110.html

https://zhidao.baidu.com/question/1861425098722336547.html