Checkbox value attribute
Checkbox Object
Definition and Usage
The value attribute sets or returns the value of the checkbox's value attribute.
The checkbox's value attribute value is not shown in the user interface. The value attribute is used for form data submission (only checked checkboxes pass data to the server; if nothing is selected, no checkbox data is passed).
Syntax
Set the value attribute:
checkboxObject.value="
value
"
Return the value attribute:
checkboxObject.value
Browser support





All major browsers support the value property.
Example
Example
Display the value associated with the checkbox:
Try it »
Checkbox Object