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

RE: HTML Table Markup

From: Bailey, Bruce <Bruce.Bailey@ed.gov>
Date: Thu, 9 Sep 2004 15:48:19 -0400
Message-ID: <CCDBDCBFA650F74AA88830D4BACDBAB504FBD8@wdcrobe2m02.ed.gov>
To: "Chris Ridpath" <chris.ridpath@utoronto.ca>, <w3c-wai-ig@w3.org>

> We agreed ... that layout tables cannot use TH elements.


> We agreed that data tables must use TH elements.

No, not all, but this was the question I am seeking clarification on!

First of all, <q>identify row and column headers</q> encompasses other techniques.  I include a message below that Andrew Kirkpatrick sent me (that was meant to get posted to the IG list) which has some very nice examples of this.

Does 5.1 require only _changing_ TD to TH (or other technique) or does it go so far to require the _addition_ of whole rows?

It may be that this comes down to parsing the word "use".  I do NOT believe that there is consensus on this point.  I have checked the mail archive and minutes for previous discussion on this point.  There has been plenty of discussion (on-going for years actually) on this, but nothing definitive that I could find (nor recollect).  If I am mistaken on this point, please provide a telling URL!

When I first posted the start of this thread, I thought I was asking an easy question!

I now believe that this is one of those ambiguities endemic to WCAG1.  Those endemic ambiguities are, of course, part of the motivation for the continuing work on WCAG2.

If we agree that data tables absolutely require use TH (or other technique) we must do so with consideration of very simple data tables.  I gave the example of a 3x2 table with three names and three phone numbers.  Do we want 5.1 to require the addition of a heading row in this case?

I am comfortable if this IS the consensus.  I just want the point fully considered.  If this is the case, the techniques document should be updated with the example of adding a header row.


-----Original Message-----
From: Andrew Kirkpatrick [mailto:andrew_kirkpatrick@wgbh.org]
Sent: Saturday, September 04, 2004 8:44 PM
To: w3c-wai-ig@w3.org; Bailey, Bruce
Subject: RE: Does 5.1 absolutely require TH?

Bailey, Bruce wrote:
> So, does 5.1 necessarily require the _addition_ of TH?

5.1 States: For data tables, identify row and column headers.

I'm imagining Bruce on the stand for some case, being asked, "is it
necessary to use table header elements to identify table headings, or can it
be done any other way?"  Or he's talking to a developer who's trying to
justify why something they've done meets the guidelines.

So if I do the following, is it 100% clear what the headings are?
<td scope="col">A</td><td scope="col">B</td>

What if I did this?
<td id="a">A</td><td id="b">B</td>
<td headers="a">foo</td><td headers="b">bar</td>

How about:

This one would be clear to a sighted person, shouldn't assistive
technologies be able to pick up on something of this sort?
.z font-weight: bold;
<td class="z">A</td><td class="z">B</td>

The HTML recommendation states:
The TH element defines a cell that contains header information.
The headers and scope attributes also allow authors to help non-visual user
agents process header information.

For a given data cell, the headers attribute lists which cells provide
pertinent header information. 
For a given header cell, the scope attribute tells the user agent the data
cells for which this header provides information. 

So to answer the question, I believe that table header elements are not
necessary, however they are pretty darn clear for a human developer looking
at the code to understand.  It is also convenient for applying styles. In
reality, we are concerned with what works with existing assistive
technologies, so we might not implement one of the examples above because it
may not work (or because we'd need to spend the time to test it out).  


Andrew Kirkpatrick
Project Manager, WGBH National Center for Accessible Media
125 Western Avenue
Boston, MA 02134
Received on Thursday, 9 September 2004 19:48:57 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 13 October 2015 16:21:29 UTC