Click to See Complete Forum and Search --> : Radio Buttons


dvxuser
04-12-2008, 07:12 PM
How is everyone doing?!
I have a general question for ya. I have a series of 10 radio buttons with a submit button at the bottom of the list. What I would like to do is assign a different URL for each of the 10 buttons, and when the user clicks the submit button it opens up the corresponding url in the same window.
Aside from placing the radio buttons and submit button withen the same form im not sure how to proceed.
Thank you for the help.
Luke

kiwibrit
04-13-2008, 07:24 AM
I would not use radio buttons for that - I guess I would use the same gif image for each of the buttons - with an associated targeted link for each calling up the url within a frame. But as I don't use frames, I will let someone else who does comment.

dvxuser
04-13-2008, 03:29 PM
Thank you for the reply
Why would you not use radio buttons? I would like the user to make a selection and then click the submit button to take them to there selection. I'm sure this is possible. If i use a gif image it will just link theme right to the site instead of making them hit the submit button correct?

dvxuser
04-13-2008, 04:40 PM
I figured it out. below is what I came up with.

<form id="form1" name="form1" method="onClick" action=""><input type=radio name="somename" onClick="
form.action = 'http://msn.com/';
"> msn
<input type=radio name="somename" onClick="
form.action = 'http://www.yahoo.com/';
"> yahoo
<input type=radio name="somename" onClick="
form.action = 'http://www.cnn.com';
">
cnn
<label>
<input name="somename" type="submit" id="somename" value="Submit" />
</label>
</form>