1. Computing

Discuss in my forum

<input type="radio">

By , About.com Guide

INPUT Radio Description:

The radio INPUT tag gives you a way to add radio buttons to .

DTD: HTML5: <!doctype html>
HTML4 Strict: <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
HTML4 Transitional or Loose: <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">

INPUT Radio Web Browser Support:

HTML Versions

INPUT Radio Attributes:

INPUT Radio Usage:

Standard input radio button

<form>
<input type="radio">
</form>
<form>
<input type="radio"& name="pet" value="dog"gt;
<input type="radio"& name="pet" value="cat"gt;
<input type="radio"& name="pet" value="rabbit"gt;
<input type="radio"& name="pet" value="horse"gt;
<input type="radio"& name="pet" value="other"gt;
</form>

See an example of a radio input tag.

INPUT Radio Special Notes:

Give several radio buttons the same name (as in example 2) to send a single value for one question to the server. Use multiple radio buttons to allow multiple choice questions where only one answer is allowed.

Use the checked attribute to define default values that will automatically be sent to the server if the reader does nothing.

More INPUT Radio Information:

  1. About.com
  2. Computing
  3. Web Design / HTML
  4. HTML and XHTML
  5. XHTML
  6. HTML Tags
  7. The INPUT Radio Tag - INPUT Radio - HTML Tag for Radio Buttons

©2013 About.com. All rights reserved.