[Webinar] Streamline your web hosting managementRegister Today

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 226
  • Last Modified:

RE: Radio Buttons

I want to have radio buttons on a CGI form...
how do u make it so only one radio button comes on in a group of them... If one button was selected .. the others would be deselected....
0
MAVERICK
Asked:
MAVERICK
1 Solution
 
clockwatcherCommented:
That's pretty much what radio buttons do.  You simply have to use the same name for your group of radio buttons.  

E.g., here's two distinct groups of radio buttons.  The first one is called groupone.  The second is called grouptwo.  Only one member of groupone can be on at a time.  The same is true for grouptwo.  Grouptwo has "Alpha" checked to start with.

<input type="radio" name="groupone">Yes<BR>
<input type="radio" name="groupone">No<BR><BR>

<input type="radio" name="grouptwo" CHECKED>Alpha<BR>
<input type="radio" name="grouptwo">Beta<BR>
<input type="radio" name="grouptwo">Gamma<BR>
0

Featured Post

Get expert help—faster!

Need expert help—fast? Use the Help Bell for personalized assistance getting answers to your important questions.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now