HTML DOM disabled Property
Complete Text Object Reference
Definition and Usage
The disabled property sets or returns whether or not a text field should be
disabled.
Syntax
textObject.disabled=true|false
|
Example
The following example disables a text field:
<html>
<head>
<script type="text/javascript">
function disableField()
{
document.getElementById("text1").disabled=true
}
</script>
</head>
<body>
<form>
<input type="text" id="text1" value="Hello world!" />
<input type="button" id="button1" onclick="disableField()"
value="Disable text field" />
</form>
</body>
</html>
|
Try-It-Yourself Demos
Disable a text field
Complete Text Object Reference
|
|
|
See why there are 20,000+ Ektron integrations worldwide.
Request an INSTANT DEMO or download a FREE TRIAL today. |
|
|
|