I am writing some inline javascript. it doesn't work, and I'm not sure why.
at the top of the index page
<meta http-equiv="Content-Script-Type" content="text/javascript" />
later I have:
<select name='id'> <option value=-1>New Entry</option> <option value='1' onclick="location.replace('index.php?page=update&id=1')">2010-06-12 16:38:08</option> <option value='2' onclick="location.replace('index.php?page=update&id=2')">2010-06-12 18:20:49</option> <option value='3' onclick="location.replace('index.php?page=update&id=3')">2010-06-13 11:39:09</option> </select>
I want the page to be replaced when one of the options was selected, but the code does not cause the page to refresh, and I'm not sure why. is something wrong with javascript?
source share