<html>
<head>
<title>Abakada HTML Demo: checked Property</title>
<link rel="stylesheet" href="/shared/netdemos.css">
<script language="JavaScript">
<!--
function chkThis ( ) {
var msg = "This property can be used to detect if a checkbox option has been selected. " +
"A script could be written to track the checkbox status and do further processing " +
"once the checkbox has been checked.";
if ( document.forms [ 0 ].elements [ 'chkBox' ].checked ) {
el = document.all ? document.all [ 'msg' ] : document.getElementById ( 'msg' );
if ( document.all ) el.innerHTML = msg;
else if ( dom ) el.childNodes [ 0 ].nodeValue = msg;
else if ( document.layers ) alert ( msg );
}
else {
if ( document.all ) el.innerHTML = "";
else if ( dom ) el.childNodes [ 0 ].nodeValue = "";
}
}
//-->
</script>
</head>
<body>
<!-- #include virtual="~/shared/top.inc" -->
<div class="header"><h2>Abakada HTML Demo: checked Property</h2></div>
<hr size=1 width=92%>
<center><br>
<form>
<p>Check here if you wish to learn more about checkboxes
<input name="chkBox" type="checkbox" onclick="chkThis ( )">
</p>
</form>
<div id="msg"></div>
</center>
<hr size=1 width=92%>
<!-- #include virtual="~/shared/viewsrc.inc" -->
</body>
</html>