WebAIM - Web Accessibility In Mind

E-mail List Archives

Re: Complex tables: Scope AND id and header attributes

for

From: Birkir R. Gunnarsson
Date: Oct 23, 2015 3:01PM


Hi

I would avoid headers/id by now (in html), it is being sunsetted and
its support by assistive technologies is no better than that of the
replacement techniques.
Also, you can no longer use the scope attribute on td cells, you must
use them on header (th or td with role="columnheader" or "rowheader")
cells.
If you want to indicate that a single row- or column header spans
multiple rows or columns, sue the rowspan or colspan attribute with
scope="rowgroup" or "colgroup".
E.g.
This header cel is header for two columns:
<th colspan="2" scope="colgroup">Phone numbers</th>

and this is a header for two rows:
<th rowspan="2" scope="rowgroup">My contact info</th>

Colgroup is decently supported on Windows, but support for rowgroup is
somewhat buggy, though getting better.
Voiceover (ioS 9.1) does not yet support colgroup properly. It will
announce the multi-column header, but does not announce the individual
column headers.
if you had this:
<table>
<tr>
<th colspan="2" scope="colgroup">Phone numbers</th>
</tr>
<tr>
<th scope="col">Personal</th>
<th scope="col">Business</th>
</tr>
<tr>
<td>919 999 9999</td>
<td>919777 8797</td>
</tr>
</table>

If you go into the first td cell using table navigation in Jaws or
NVDA, they would read:
Phone numbers, personal, 919 999 9999
Voiceover (on iOS) reads:
Phone numbers 919 999 9999.
hth
-Birkir



On 10/23/15, Dona Patrick < <EMAIL REMOVED> > wrote:
> I recall being told by someone or reading somewhere that one should not use
> both Scope AND id and header attributes in complex tables. I don't recall
> if this was HTML or PDF.
>
> Has anyone else heard this? Is it true or was it misinformation?
>
> Thanks,
>
> Dona
> > > > >


--
Work hard. Have fun. Make history.