X
Xerxes
Hi all,
I am trying to pass a value of a field as an argument to href but I am
not doing it right:
<select name="sel_name" id="sel_id"><option>....</option>....
<a href="somefile.php?new=1&s=?????>text</a>
I tried to replace ???? with:
document.getElementById['sel_id'].options[document.getElementById['sel_id'].selectedIndex].text
didn't work.
I tried to set a hidden field's value when selection changed and use
that value for ???? but that didn't work either.
<select name="sel_name" id="sel_id"
onChange=document.getElementById['hidden'].value=this.options[this.selectedIndex].text"><option>....</option>....
....
<a href="somefile.php&new=1&s=document.getElementById['hidden'].value>
I am trying to pass a value of a field as an argument to href but I am
not doing it right:
<select name="sel_name" id="sel_id"><option>....</option>....
<a href="somefile.php?new=1&s=?????>text</a>
I tried to replace ???? with:
document.getElementById['sel_id'].options[document.getElementById['sel_id'].selectedIndex].text
didn't work.
I tried to set a hidden field's value when selection changed and use
that value for ???? but that didn't work either.
<select name="sel_name" id="sel_id"
onChange=document.getElementById['hidden'].value=this.options[this.selectedIndex].text"><option>....</option>....
....
<a href="somefile.php&new=1&s=document.getElementById['hidden'].value>