I'm writing some vbscript within html and having issues with a button. I have 3 buttons. One is called Enter which just more or less reloads the page. An exit button that goes back to the mainpage and a button called "New Station" that I just want to set a variables value. The problem is whenever I hit the enter button, it seems to reset that variable anyway. I don't know why. Here is my code:
<INPUT id=submit1 style="FONT-WEIGHT: bold; COLOR: mediumblue; HEIGHT: 20; FONT-SIZE: 12" type=submit value=Enter name=submit1>
<input style="FONT-WEIGHT: bold; COLOR: mediumblue; HEIGHT: 20; FONT-SIZE: 12" type=button value="New Station" onclick='<%session("mpr") = "done"%>'>
<INPUT style="FONT-WEIGHT: bold; COLOR: mediumblue; HEIGHT: 20; FONT-SIZE: 12" type=button value="Exit" name=exit onclick="window.location='mainpage.asp'">
Does anyone have any ideas why it seems to change session("mpr") = "done" even when I don't click the New Station button?
<INPUT id=submit1 style="FONT-WEIGHT: bold; COLOR: mediumblue; HEIGHT: 20; FONT-SIZE: 12" type=submit value=Enter name=submit1>
<input style="FONT-WEIGHT: bold; COLOR: mediumblue; HEIGHT: 20; FONT-SIZE: 12" type=button value="New Station" onclick='<%session("mpr") = "done"%>'>
<INPUT style="FONT-WEIGHT: bold; COLOR: mediumblue; HEIGHT: 20; FONT-SIZE: 12" type=button value="Exit" name=exit onclick="window.location='mainpage.asp'">
Does anyone have any ideas why it seems to change session("mpr") = "done" even when I don't click the New Station button?