根据优良的HTML5规范:
甲 按钮 没有元素 类型 指定属性表示相同的事情与它的类型属性集的按钮元件到 “提交” 。
并且a
<button type="submit">提交表单而不是像简单
<buttontype="button">的按钮那样操作。
在HTML4规范说同样的事情:
type = commit | button | reset [CI]
此属性声明按钮的类型。可能的值:
submit
:创建一个提交按钮。这是默认值。reset
:创建一个重置按钮。button
:创建一个按钮。
所以你的
<button>元素:
<button >Button_1</button><button >Button_2</button>
与以下相同(在兼容的浏览器中):
<button type="submit" >Button_1</button><button type="submit" >Button_2</button>
只要您按下其中一个按钮,就会提交表格。
解决方案是使用普通按钮:
<button type="button" >Button_1</button><button type="button" >Button_2</button>
type="button"尽管有标准说明,但某些版本的IE还是默认使用。
type使用
<button>just时,应始终指定属性,以确保获得期望的行为。



