W3C home > Mailing lists > Public > w3c-wai-ig@w3.org > July to September 2006

Re: a single label where multiple fields follow

From: Paul Collins <paul@pokelondon.com>
Date: Thu, 21 Sep 2006 14:44:54 +0100
Message-ID: <012001c6dd84$1ea10b10$a318a8c0@dev2>
To: <w3c-wai-ig@w3.org>
Could you wrap the label around all of the inputs? 

<label>text here<input 1><input 2><input 3></label>

A guess only
  ----- Original Message ----- 
  From: David Poehlman 
  To: Antony Tennant 
  Cc: w3c-wai-ig@w3.org 
  Sent: Thursday, September 21, 2006 2:17 PM
  Subject: Re: a single label where multiple fields follow



  title is not adaquuately supported by at and many browsers.

  On Sep 21, 2006, at 8:43 AM, Antony Tennant wrote:

  Hi

  I would like to get some opinions on the best practise for assigning  
  <label for""> to inputs where there are multiple inputs for example  
  for telephone numbers, sort codes, credit card numbers. I have had a  
  look at the friends of ed book "Web Accessibility" and my  
  understanding is that the title attribute should be used for the  
  additional fields and <th> where possible.

  Picking examples from websites, what would the best approach be  
  (assume the fields cannot be changed to a single field)

  For a credit card entry that is split across 4 fields, what would be  
  placed in the following titles where below there is "????"
  <label for"creditcard">credit card number</label><input type="text"  
  id ="creditcard" title="first 4 digits">&nbsp;<input type="text"  
  title="????">&nbsp;<input type="text" title="????">&nbsp;<input  
  type="text"  title="????">

  For a telephone number, would this be acceptable ie the label to the  
  first field that has a title and the sceond field with a title.
  <label for"telephone">telephone number</label><input type="text" id  
  ="telephone" title="area code">&nbsp;<input type="text" title="local  
  number">

  For a bank sort code
  <label for"sortcode">sort code</label><input type="text" id  
  ="sortcode" title="first 2 digits">&nbsp;<input type="text"  
  title="middle 2 digits">&nbsp;<input type="text" title="last 2 digits">

  Any further guidence would be appreciated

  Thanks

  Antony
Received on Thursday, 21 September 2006 13:45:24 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Tuesday, 19 July 2011 18:14:25 GMT