Re: Question on labels

Charles McCathieNevile wrote:

>I wondered why there is a label used to identify the form controls 
>such as the search field which does not provide any actual 
>labelling, just an accesskey which could be attached directly to the 
>form control in question?

Thanks for the idea, Charles. The labels were added in revision 4.716
when the tables were removed in favor of CSS. It's been a while but
think I copied them from WDG. Did I get them wrong?

 From http://www.htmlhelp.com/reference/html40/forms/label.html

<P>
   <LABEL ACCESSKEY=S>
     <INPUT TYPE=checkbox NAME=save VALUE=yes>
     Save user name and password in a cookie
   </LABEL>
</P>

Does this look better?

<form method="get" action="http://www.google.com/custom">
<div><a class="navlink" href="http://www.google.com"><img
src="Icons/Logo_25wht.gif" width="75" height="32"
alt="Google" /></a><br />
<input type="text" accesskey="E" size="15" tabindex="1"
id="inputField" name="q" maxlength="255" value="Search W3C" />
<input type="submit" accesskey="G" value="Go" tabindex="2"
id="goButton" name="sa" /><br />
<input type="hidden" name="cof"
value="T:black;LW:72;ALC:#ff3300;L:http://www.w3.org/Icons/w3c_home;LC:#000099;LH:48;BGC:white;AH:left;VLC:#660066;GL:0;AWFID:0b9847e42caf283e;" 
/>
<input type="hidden" id="searchW3C" name="sitesearch" checked="checked"
value="w3.org" /><input type="hidden" name="domains"
value="w3.org" /></div>
</form>

-- 
Susan Lesch           http://www.w3.org/People/Lesch/
mailto:lesch@w3.org               tel:+1.858.483.4819
World Wide Web Consortium (W3C)    http://www.w3.org/

Received on Thursday, 5 June 2003 21:02:55 UTC