Button value Property
Button Object
Definition and Usage
The value property sets or returns the value of the value attribute on the button.
The value attribute specifies the text displayed on the button
Important: If you use the button element in an HTML form, different browsers will display different values. Internet Explorer displays the value in the tag, while other elements display the value of the value attribute. In an HTML form you can use the input element to display a button.
Syntax
buttonObject.value=
value
Browser support





All major browsers support the value property.
Example
Example
Return the text displayed on the button:
The text of the button:
Try it »
Button Object