HTML DOM Radio object
Radio Object
Radio objects represent radio buttons in HTML forms.
In HTML forms, one Radio object is created for every time it appears.
A turn button is one of a set of mutually exclusive option buttons. When a button is selected, the previously selected button becomes unchecked.
When a turn button is selected or not selected, the button triggers the onclick event handle.
You can access the Radio object by traversing the form's array of elements, or by using document.getElementById().
Radio object properties
W3C: W3C standard.
Attributes | describe | W3C |
---|---|---|
checked | Set or returns the status of the radio button. | Yes |
defaultChecked | Returns the default status of the radio button. | Yes |
disabled | Set or return to whether the radio button is disabled. | Yes |
form | Returns a reference to a form that contains this radio button. | Yes |
name | Set or returns the name of the radio button. | Yes |
type | Returns the form type of the radio button. | Yes |
value | Set or returns the value of the value attribute of the radio button. | Yes |
Standard properties and events
Radio objects also support the standard properties and events.