disabled 属性可设置或返回是否禁用密码域。
passwordObject.disabled=true|false
下面的例子仅用了该密码域:
<html>
<head>
<script type="text/javascript">
function disablePassword()
{
document.getElementById("password1").disabled=true
}
</script>
</head>
<body>
<form>
<input type="password" id="password1" />
<input type="button" id="button1" onClick="disablePassword()"
value="Disable password field" />
</form>
</body>
</html>