HTML 5 has some new attributes, and some HTML 4.01 attributes are no longer
supported.
Tips and Notes
Tip: Use this tag in the form element to accept user input.
Example
Source
Output
<select>
<option value ="volvo">Volvo</option>
<option value ="saab">Saab</option>
<option value ="opel">Opel</option>
<option value ="audi">Audi</option>
</select>
Attributes
4: indicates if the attribute is defined in HTML 4.01
5: indicates if the attribute is defined in HTML 5
Attribute
Value
Description
4
5
autofocus
true
false
Makes the select field focused on page load
5
data
url
For inserting data automatically
5
disabled
true
false
When true, it disables the drop-down list
4
5
form
true
false
Defines one ore more forms the select field belongs to.
5
multiple
true
false
When true, it specifies that multiple items can be selected at a time
4
5
name
unique_name
Defines a unique name for the drop-down list
4
5
size
number
Defines the number of visible items in the drop-down list.
Not supported.
Whether you're new to XML or already an advanced user, the user-friendly views
and powerful entry helpers, wizards, and debuggers in XMLSpy are designed to
meet your XML and Web services development needs from start to finish.
W3Schools provides material for training only. We do not warrant the correctness of its contents.
The risk from using it lies entirely with the user.
While using this site, you agree to have read and accepted our
terms of use and
privacy policy.