|
|
Checkbox disabled Property
Checkbox Object
Definition and Usage
The disabled property sets or returns whether or not a checkbox should be
disabled.
Syntax
|
checkboxObject.disabled=true|false
|
Example
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 »
|
Checkbox Object
|
|
|