Feed on
Posts
Comments

Fieldsets and Legends

Difficulty: Advanced

Category:

  • Structure
  • Presentation

Groups of checkboxes and radio buttons often have a higher-level description that indicates the purpose of the grouping. In such cases, a fieldset and legend should be used to visually identify the grouping and to ensure that the higher-level legend is read by assistive technologies.

<fieldset><legend>Choose your shipping method</legend>
Radio buttons for shipping options
</fieldset>

Fieldsets can be used for groupings of other types of form elements (e.g., “Shipping Address” vs. “Billing Address”), but should be used with care because the legend is identified for each form element in the fieldset.

For more information, see Creating Accessible Form Controls

Leave a Reply

MDTAP | 2301 Argonne Drive, Room T17 Baltimore, Maryland 21218| Voice: 410-554-9230 Toll Free ⁄ Voice 1-800-832-4827|Email: mdtap@mdtap.org