<datalist>
HTML DOM Datalist object
Datalist object
The Datalist object is new in HTML5.
Datalist objects represent HTML <datalist> elements.
Access the Datalist object
You can use the getElementById() function to access <datalist> elements:
var x = document.getElementById("myDatalist");
Create a Datalist object
You can use the document.createElement() method to create <datalist> elements:
var x = document.createElement("DATALIST");
A collection of Datalist objects
Collection | Description |
---|---|
options | Returns a collection of all options in a datalist |
Standard Properties and Events
Datalist objects also support standard properties and events .
Related pages
HTML Tutorial: HTML Forms
HTML Reference Manual: HTML <datalist> Tag