Ok, let's try this one.
What I'm trying to do, is have this javascript fire when the user presses a button. The script should get the value of the currently selected item in a listbox then run my cgi script on the server. I've done similar things, but this one keeps giving me 'javascript error!' and I can't figure out what I'm doing wrong. 'promos' is the form name and 'promolist' is the listbox (SELECT) name. Any help out there?
The HTML code that should fire this function off is:
What I'm trying to do, is have this javascript fire when the user presses a button. The script should get the value of the currently selected item in a listbox then run my cgi script on the server. I've done similar things, but this one keeps giving me 'javascript error!' and I can't figure out what I'm doing wrong. 'promos' is the form name and 'promolist' is the listbox (SELECT) name. Any help out there?
Code:
<script TYPE="text/javascript"> function GetPromoDesc() { var pID=document.promos.promolist.selected; window.location = "./promodesc.exe?pID"; } </script>
Code:
<div id="wb_AdvancedButton1" style="position:absolute;left:177px;top:338px; width:282px;height:22px;z-index:26" align="center"> <button id="AdvancedButton1" type="button" onClick="GetPromoDesc" name="AdvancedButton1" style="width:282px;height:22px"><p> <font style="font-size:13px" color="#000000" face="Arial"> Show Full Description</font></p></button></div>
Comment