O'Reilly logo

Web Programming with HTML5, CSS, and JavaScript by Dean

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

10.6 Radio Buttons

So far, we’ve covered several form controls in depth—the button, text, and number controls. Also, we briefly introduced you to several other controls, such as the email and password controls. Now it’s time for the radio button control. Radio buttons come in a group, where only one radio button in a group can be selected at a time. When one of the buttons in the group is clicked, it gets selected and the other buttons get unselected. That’s different from regular buttons, which are standalone entities.

HTML Attributes

Here are the radio button control’s more important attributes:

Radio Button Control Attributes

type

name

value

checked

required

disabled

onclick

To create a radio button control, ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required