View Full Version : Radio Buttons not Canceling
halek
11-20-2004, 05:31 AM
I am new to Web design, but am trying to do apage for a volunteer group I work with. Using Front Page 2002 I created a couple of Radio Buttons for a Yes/no answer. The buttons did not act as I expected, where only one could be selected.
I just noted on a tutorial the recommendation that all the buttons be given the exact same name. I did not do that. Is that the reason they did not function as expected? I tried putting them in a group but that did not solve the problem. :confused:
Thanks for any help!
Jalenack
11-20-2004, 07:08 AM
ok its a pretty simple solution...there are two things that are involved in a radio button: the value and the name. The value is the specific thing that a user chooses. The name is the group of choices that are all lumped together...maybe an example would be better:
<input type="radio" name="gender" value="male" />
<input type="radio" name="gender" value="female" />
The user can now click one or the other...the name and values can be anything you want...just remember when you get the email from the submitted form it will come out like, or however you view forms..
Gender = Male
so you want to use good words for 'name' and 'gender' if you want to understand what the user has selected...
For more information on forms and other kinds of web coding, check out the W3 schools (this link talks about !Using Forms (http://www.w3schools.com/html/html_forms.asp) )
Hope this answers your question
halek
11-20-2004, 04:43 PM
Hope this answers your question
Thanks!
The "Group name" aspect was what I missed.
Things working great now.
vBulletin® v3.8.2, Copyright ©2000-2012, Jelsoft Enterprises Ltd.