PDA

View Full Version : Form Problem


ausnrl
02-02-2006, 11:27 AM
<form name="form1" method="get" action="">
<select name="select" size="1">
<option value="playersbears.php">Bears</option>
<option value="playersblackhawks.php">Black Hawks</option>
<option value="playerscriminals.php">Criminals</option>
<option value="playersdevils.php">Devils</option>
<option value="playerssilverbacks.php">Silverbacks</option>
<option value="playerswarriors.php">Warriors</option>
</select>
<input type="submit" name="Submit" value="Go">
</form>

Thats the code. When you hit the go button it just stays on the same page what do i have to insert, change or remove?

NancyJ
02-02-2006, 12:29 PM
the page you want to go to needs to be in action = ""

ausnrl
02-02-2006, 12:41 PM
I want every drop down to go to a different page. So would i wrap each one in a href tags?

NancyJ
02-02-2006, 12:47 PM
No, you need to apply javascript to achieve the effect you want.

http://www.quirksmode.org/js/select.html

just change the go() function to trigger from the onclick event of your 'go' button instead of the onchange event for the select.

ausnrl
02-02-2006, 01:13 PM
I dont no you seem pretty good at this stuff. It didnt work so heres all the files can you check em for me and edit any problems. Javascript aint really my thing.

ausnrl
02-03-2006, 11:44 AM
Well i seemed to get it to work with one form but 2 forms in one page didnt. Can some form wizz please fix it up.