w3-video.com logo

HTML5 Tutorial

Home HTML5 XAMPP .htaccess Firefox Notepad++

Share it

select disabled attribute

The disabled attribute on the select element:


2.disabled="",  , disabled<select disabled> ... <⁄select>
<select disabled=""> ... <⁄select>
<select disabled="disabled"> ... <⁄select>

Video demonstration select disabled attribute

HTML5 select disabled attribute Tutorial

min video details
00:00 video tutorial: disabled attribute on select element
00:09 the select control, by default is enabled; users can interact with it: it's clickable, options inside it display and can be selected
00:13 the disabled attribute on select control, allows us to disable the control → users can't interact with it anymore
00:20 the minimized form of the attribute
00:24 the select control has been disabled
00:26 disabled attribute if present on select control, may have the next 2 values:
- empty string: ""
- attribute's canonical name: "disabled"
both values return the true value → the control is disabled
for false value simply don't add this attribute on the control
select intro select browser display select parents - children select Placeholder Label Optionselect Constraintsselect Exampleselect syntaxselect autofocus attributeselect multiple attributeselect required attributeselect size attribute