Small typo on my part (forgot the "ById"):
HTML Code:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
<html>
<head>
<title></title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<script type="text/javascript">
function hide_menu(id){
document.getElementById(id).style.display = "none";
}
function show_menu(id){
document.getElementById(id).style.display = "block";
}
</script>
</head>
<body>
<button onclick="if (document.getElementById('idOfDiv').style.display=='none') show_menu('idOfDiv'); else hide_menu('idOfDiv');">Show/Hide</button>
<div id="idOfDiv"> Show me, hide me, anyway you want me....</div>
</body>
</html>
Bookmarks