HTML/Elements/input/button

From Web Education Community Group
< HTML‎ | Elements‎ | input
Jump to: navigation, search

<input type="button">

The button state represents a button with no default behavior.

HTML Attributes

  • name = string
    Gives the name of the input element.


  • value = string
    Gives the default value of the input element.


Example

Example A

[try it]

<input type="button" value="Show Hint" onclick="alert('This 15-20 minute piece was composed by George Gershwin.')">

Input button01.png

HTML Reference

The HTML5 specification defines the button state in 4.10.7.1.22 BUTTON STATE.