HTML DOM disabled Property
Complete Checkbox Object Reference
Definition and Usage
The disabled property sets or returns whether or not a checkbox should be
disabled.
Syntax
checkboxObject.disabled=true|false
|
Example
The following example disables the checkbox:
<html>
<head>
<script type="text/javascript">
function disable()
{
document.getElementById("check1").disabled=true
}
</script>
</head>
<body>
<form>
<input type="checkbox" id="check1" />
<input type="button" onclick="disable()" value="Disable Checkbox" />
</form>
</body>
</html>
|
Try-It-Yourself Demos
Disable a checkbox
Complete Checkbox Object Reference
Learn XML with <oXygen/> XML Editor - Free Trial!
|
|
oXygen helps you learn to define,
edit, validate and transform XML documents. Supported technologies include XML Schema,
DTD, Relax NG, XSLT, XPath, XQuery, CSS.
Understand in no time how XSLT and XQuery work by using the intuitive oXygen debugger!
Do you have any XML related questions? Get free answers from the oXygen
XML forum
and from the video
demonstrations.
Download a FREE 30-day trial today!
|
|