Collection of references for web development.

HTML select tag


The HTML <select> element represents a drop-down list.


Attribute Value Description
autofocus boolean Specifies if the element should automatically have focus when the document loads.
disabled boolean Specifies whether the element should be disabled or not (user is unable to click or control if disabled).
form ID Specifies the form(s) that the element belongs to.
multiple boolean Specifies whether the user can enter more than one value.
name string Specifies the name of the element.
required required Specifies that the elements value is required before submitting the form.
size size Specifies the size of the element.


<select name="gender">
	<option value="male">Male</option> 
	<option value="female" selected>Female</option>