Easy Tutorial
❮ Att Body Alink Att Hr Width ❯

HTML <optgroup> disabled Attribute

HTML <optgroup> Tag

Example

A disabled optgroup:


Browser Support

All major browsers support the disabled attribute.

Note: Internet Explorer 7 and earlier versions do not support the disabled attribute of the <optgroup> tag.


Definition and Usage

The disabled attribute is a boolean attribute.

The disabled attribute specifies that the optgroup should be disabled.

A disabled optgroup is unusable and un-clickable.

The disabled attribute can be set to keep a user from using the optgroup until some other condition has been met (like selecting a checkbox, etc.). Then, a JavaScript could remove the disabled value, and make the optgroup usable.


Differences Between HTML 4.01 and HTML5

None.


Differences Between HTML and XHTML

In XHTML, attribute minimization is forbidden, and the disabled attribute must be defined as <optgroup disabled="disabled">.


Syntax

❮ Att Body Alink Att Hr Width ❯