Private archive copy · Unofficial site · Content copyright belongs to Runoob Tutorial and the original authors · View Original

HTML command disabled attribute

HTML disabled attribute

HTML command Tag Reference HTML tag

Example

A disabled element:

onclick="setAlign('center')">Center

Try it »


Browser support

Internet ExplorerFirefoxOperaGoogle ChromeSafari

Currently, almost all major browsers do not support the disabled attribute.

**Note:** Internet Explorer 9 supports the disabled attribute (only IE9 supports it, versions before or after do not).


Definition and Usage

The disabled attribute is a boolean attribute.

The disabled attribute specifies that the command element should be disabled.


Differences between HTML 4.01 and HTML5

The tag is new in HTML5.


Differences between HTML and XHTML

In XHTML, attribute minimization is forbidden; the disabled attribute must be defined as .


Syntax


HTML command Tag Reference HTML tag