Re: label tag question

Beheler Kim wrote:

> To comply with Section 508, does the textbox need to be associated with 
> the button?

Unfortunately, that's not directly possible. However, I'd suggest 
something like

<form action="..." method="...">
     <label for="searchterm">Search for:</label>
     <input type="text" name="q" id="searchterm" value="" />
     <input type="submit" value="search" />
</form>

and use CSS to hide the label (unless I'm mistaken, even hiding it via 
CSS still retains the necessary association used by AT such as 
screenreaders)

If you're after XHTML1.1, you may also want to wrap the form's content 
in a fieldset or other block level element (and obviously then add extra 
styling to, for instance, suppress the standard border that comes with 
fieldsets)

-- 
Patrick H. Lauke
_____________________________________________________
re·dux (adj.): brought back; returned. used postpositively
[latin : re-, re- + dux, leader; see duke.]
www.splintered.co.uk | www.photographia.co.uk
http://redux.deviantart.com

Received on Wednesday, 30 March 2005 19:39:11 UTC