Name
DISABLED — NN n/a IE 4 HTML 4
Synopsis
DISABLED
Optional
A disabled INPUT element appears grayed out on the
screen and cannot be activated by the user. In Windows, a disabled
form control cannot receive focus and does not become active within
the tabbing order rotation. HTML 4.0 also specifies that the
name/value pair of a disabled INPUT element should
not be sent when the form is submitted. INPUT
elements that normally perform submissions do not submit their form
when disabled.
The DISABLED attribute is a Boolean type, which
means that its presence in the attribute sets its value to
true. Its value can also be adjusted after the
fact by scripting (see the button object in Chapter 9).
Input Types
All.
Example
<BUTTON TYPE="submit" DISABLED>Ready to Submit </BUTTON>
Value
The presence of the attribute disables the element.
Default
false
Object Model Reference
- IE
[window.]document.formName.inputName.disabled
[window.]document.forms[i].elements[i].disabled
[window.]document.all.elementID.disabled
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access