Adds an option element to the select element.
Method of dom/HTMLSelectElementdom/HTMLSelectElement
Syntax select.add(element, beforeElement);
Parameters element
The option element to add.
beforeElementThe element before which the new option will be placed. If no value is given, the method places the element at the end of the collection.
Return ValueNo return value
Usage This method adds an option element to a select block.
Notes
Before you can add an element to a collection, you must create it first by using the createElement method.
Related specificationsMicrosoft Developer Network: [Windows Internet Explorer API reference Article]
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4