can any one help me out.what is the problem with this code?
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Untitled Document</title>
<script type="text/javascript">
function combofunction(){
// actions that you want to perform
//You will receive a different greeting based
//on what day it is. Note that Sunday=0,
//Monday=1, Tuesday=2, etc.
var value=document.getElementById("htmlcombo").value;
//var d=new Date();
//var theDay=d.getDay();
switch (value)
{
case 1:
document.getElementById("1").style.visibility = "visible";
//document.write("Finally Friday");
break;
case 2:
document.getElementById("2").style.visibility = "visible";
//document.write("Super Saturday");
break;
case 3:
document.getElementById("3").style.visibility = "visible";
//document.write("Sleepy Sunday");
break;
default:
//document.write("I'm looking forward to this weekend!");
}
}
</script>
</head>
<body>
<select name="htmlcombo" id="htmlcombo">
<option name="box1" value="1">Display Text1</option>
<option name="box2" value="2">Display Text2</option>
<option name="box3" value="3">Display Text3</option>
</select>
<input type="button" name="combovalue" value="Get Combo Value" onclick="combofunction()">
<div id="1" style="visibility:visible" >hello1</div>
<div id="2" style="visibility:hidden">hello2</div>
<div id="3" style="visibility:hidden">hello3</div>
<div id="4" style="visibility:hidden">hello4</div>
</body>
</html>