34

Are there any major differences between <button type="button" name="theButton">SUBMIT</button> and <input type="submit" value="SUBMIT" name="theButton" />

Also, can you use <button type="submit" name="theButton">SUBMIT</button>?

Cody Gray - on strike
  • 239,200
  • 50
  • 490
  • 574
DarkLightA
  • 14,980
  • 18
  • 49
  • 57

2 Answers2

14

Here's a page describing the differences (basically you can put html into a <button></button>

And an other page describing why people avoid <button></button> (Hint: IE6)

Reference: <button> vs. <input type="button" />. Which to use?

Also have a look at this slideshow about button.

Community
  • 1
  • 1
Zain Shaikh
  • 6,013
  • 6
  • 41
  • 66
2

<button type="button" name="theButton">SUBMIT</button>

Won't submit a form (bugs in some browsers aside)

<input type="submit" value="SUBMIT" name="theButton" />

Will submit a form.

Also, can you use <button type="submit" name="theButton">SUBMIT</button>?

Will submit a form, but doesn't have a value (bugs in IE aside)

Quentin
  • 914,110
  • 126
  • 1,211
  • 1,335