Skip to content

Instantly share code, notes, and snippets.

@jlindley
Created May 21, 2009 15:27
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jlindley/115522 to your computer and use it in GitHub Desktop.
Save jlindley/115522 to your computer and use it in GitHub Desktop.
<html>
<head>
<script type="text/javascript">
function is_it_private(){
var is_private_element = document.getElementsByName("is_private")[0];
alert("Value is " + is_private_element.checked );
}
window.onload = is_it_private;
</script>
</head>
<body>
<form >
<p>
<label>Private?</label>
<input name="is_private" type="checkbox" />
</p>
</form>
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment