WebAIM - Web Accessibility In Mind

E-mail List Archives

Re: Section 508 - Form Field Label

for

From: Michael.Moore@dars.state.tx.us
Date: Nov 12, 2010 8:09AM


No,

"CBP" needs to be contained in a label element that is programmatically bound to the input.

<input type="checkbox" id="ch1a" name="whatever" class=...>
<label for="ch1a">CPB</label>

Nothing in the title of the div provides any semantic meaning to the AT. I am not even aware of any screen reader AT that will read the titles in divs.

Mike Moore


-----Original Message-----
From: <EMAIL REMOVED> [mailto: <EMAIL REMOVED> ] On Behalf Of Barry Johnson
Sent: Friday, November 12, 2010 8:59 AM
To: <EMAIL REMOVED>
Subject: [WebAIM] Section 508 - Form Field Label

Below is (simplified) code where TITLE is an attribute of a DIV that
contains a form field. Is this an acceptable way to label a form field for
Section 508 Compliance?



<div *title='CBP'>*

*<input type='checkbox' igchk='1' class='igt_align'>*<span igtxt='1' class="
">CBP</span></div>