Object: HTMLOptionElement
HTMLOptionElement properties
|
Property name |
Type |
Description |
Status |
Support level |
Availability |
|---|---|---|---|---|---|
|
boolean |
When true, indicates that the option is selected by default. |
writable |
DOM 2 HTML |
4.6 or later |
|
|
boolean |
When true, indicates that the option is not available. |
writable |
DOM 2 HTML |
4.6 or later |
|
|
Returns the form that contains the option. If this element is not contained by a form, this property returns null. |
read only |
DOM 2 HTML |
4.6 or later |
||
|
int |
Returns the position of this option within the parent <select> element. |
read only |
DOM 2 HTML |
4.6 or later |
|
|
DOMString |
Specifies a label for the option. |
writable |
DOM 2 HTML |
4.6 or later |
|
|
boolean |
When true, indicates that the option is currently selected. |
writable |
DOM 2 HTML |
4.6 or later |
|
|
DOMString |
Specifies the text contained within the <option> element. |
writable |
DOM 2 HTML |
4.6 or later |
|
|
DOMString |
Specifies the value of the option that is sent to the server when the form is submitted. |
writable |
DOM 2 HTML |
4.6 or later |