INPUT TYPE="RADIO"


The radio button is used to select only one item from a list. If you do not believe me test the buttons shown here:

Please choose an ice cream flavor.

chocolate grape lemon strawberry vanilla
As you can see, you cannot have tutti-frutti. Radio buttons allow for only one selection. The input type is called "radio" because they act as push buttons on an old car radio.

Radio buttons use the following syntax:

<INPUT TYPE="RADIO" NAME="name of variable" VALUE="value of variable"> text description

Where VALUE will be assigned to NAME when the particular radio button is selected.

Optionally you may add the CHECKED attribute. The CHECKED attribute will show the button as being pre-selected.

How can I select more than one flavor of ice cream?


[INDEX] [PREVIOUS] [NEXT PAGE] [CHAPTER 9]

Valid HTML 3.2!