English | 简体中文 | 繁體中文 | Русский язык | Français | Español | Português | Deutsch | 日本語 | 한국어 | Italiano | بالعربية
Die Eigenschaft Disabled ist ein boolesches Attribut. Ein deaktivierter <input>-Element kann nicht verwendet und nicht geklickt werden. Wenn vorhanden, legt es fest, dass das <input>-Element deaktiviert sein soll.
HTML-Formular mit deaktivierten Eingabefeldern:
!DOCTYPE html <html> <head> <title>HTML: <input> disabled Eigenschaft - Grundlegende Anleitung (oldtoolbag.com)</title> <body> <form action="action_page.php"> Vorname: <input type="text" name="fname"><br> Nachname: <input type="text" name="lname" disabled><br> <input type="submit" value="Submit"> </form> </html>Testen Sie es heraus ‹/›
IEFirefoxOperaChromeSafari
All major browsers support the disabled attribute.
The disabled attribute is a boolean attribute.
If present, it specifies the <input> element that should be disabled.
Disabled input elements cannot be used and cannot be clicked.
You can set the disabled attribute to prevent the user from using the <input> element until certain other conditions are met (such as checking a checkbox, etc.). Then, JavaScript can remove the disabled value and make the <input> element available.
Hint: Disabled <input> elements in the form will not be submitted!
Note:The disabled attribute does not apply to <input type="hidden">.
None.
In XHTML, attribute abbreviation is prohibited, the disabled attribute must be defined as <input disabled="disabled" />。
<input disabled>HTML <input> Tag