W3C home > Mailing lists > Public > w3c-wai-ig@w3.org > April to June 2002

Label versus Title

From: Andy J. W. Affleck <listaccount@raggedcastle.com>
Date: Fri, 19 Apr 2002 15:11:15 -0400
To: <w3c-wai-ig@w3.org>
Message-ID: <B8E5E413.E3A7%listaccount@raggedcastle.com>
I've read through the archives and the common sentiment seems to be that in
cases where you have one label but two or more controls, you use the label
tag for the actual printed label and then use the title attribute in the
form controls for the remaining items.

In other words:

For 

   Please enter your birth month and year: [Month Text Box] [Year Text Box]

We'd do the markup as:

<label for="month">Please enter your birth month and year:</label> <input
type="text" id="month"> <input type="text" id="year" title="Enter year">


But what about:

<label for="month">Please enter your birth month</label> and <label
for="year">year</label>:<input type="text" id="month"> <input type="text"
id="year">


Or even:

<label for="month">Please enter your birth month</label> and year:<input
type="text" id="month"><span class="invisibleText"><label for="year">Enter
your birth year</label></span> <input type="text" id="year">


Thoughts?

-A 
Received on Friday, 19 April 2002 15:11:25 GMT

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