Forms are a Web developer's most important tool for gathering information from users. E-commerce sites use forms to find out what people want to buy, where they want their purchases delivered, and how they're going to pay. Distance- and e-learning sites use forms for a variety of purposes. Students complete a form when they register or when they provide a profile to introduce themselves to other members of the class. Forms are at the heart of message boards, too. When a student contributes a message to a class discussion forum, she or he enters the text in a form. And when students take tests online, they usually use a form to record and submit their responses.
Forms are powerful tools. But they can pose significant accessibility barriers, especially for people who use screen readers, talking browsers, or refreshable Braille displays. In order for these assistive technology devices to work correctly, the form controls (text input fields, buttons, and so on) must be labeled in such a way that the assistive technology can associate the correct label with the form control.
HTML Elements and Attributes Addressed in This Chapter
<form>, <fieldset>, <legend>, <caption>, <label>, <input>, <td>, <table>, <select>, <option>
id, name, for, type, value, selected, checked
Accessibility Checkpoints and Standards Addressed in This Chapter
Web Content Accessibility Guidelines 1.0 Checkpoints
9.3. For scripts, specify logical event handlers rather than devicedependent event handlers. [Priority 2]
10.2. Until user agents support explicit associations between labels and form controls, for all form controls with implicitly associated labels, ensure that the label is properly positioned. [Priority 2]
12.3. Divide large blocks of information into more manageable groups where natural and appropriate. [Priority 2]
12.4. Associate labels explicitly with their controls. [Priority 2]
Section 508 Standards, §1194.22
(n) When electronic forms are designed to be completed on-line, the form shall allow people using assistive technology to access the information, field elements, and functionality required for completion and submission of the form, including all directions and cues.
(p) When a timed response is required, the user shall be alerted and given sufficient time to indicate more time is required.