Form Tags
RADIO
The Radio Button control
is useful for getting answers to yes/no questions, or selecting one of a group of options. Use Radio buttons when
your visitor must select an option.
Radio buttons work
in groups. Selecting any one of the buttons in the group turns off the others.
Example Radio Button
How do you feel about Proposition 256 that would require java programmers to leave their computers at least
once a day?
I strongly agree.
I strongly disagree
I strongly don't care
I've never heard of it before
Here's the html code:
<P>How do you feel about Proposition 154 that would require java programmers to leave their computers
at least once a day ?</P>
<P><INPUT TYPE="radio" NAME="Java Law" VALUE="Agree">I
strongly agree.<BR>
<INPUT TYPE="radio" NAME="Java Law" VALUE="Disagree">I
strongly disagree<BR>
<INPUT TYPE="radio" NAME="Java Law" VALUE="Don't care">I
strongly don't care<BR>
<INPUT TYPE="radio" NAME="Java Law" VALUE="Don't know"
CHECKED>I've never heard of it before<BR>
</P>
Parts of the Radio Tag
HTML Label (Example: "I strongly agree.")
Radio buttons are labeled with regular html text so your visitors can understand what information they are expected
to provide. You can put your label before or after the Radio tag.
Note: The label is not actually part of the Radio tag itself and is not included in the form data sent.
NAME="anytext"
The NAME is used by the Thank You page and email to name the information selected.
VALUE="anytext"
The VALUE text is submitted as the answer to the question.
Notes
You can have multiple groups of radio buttons in your form. Each button in a group has the same NAME with different
VALUEs.
You can set any one of the radio buttons in the group to checked as the default. If none are checked, and your
visitor checks one of them, there is no way to uncheck them all again -- except by hitting the Reset
button.
|