Re: th scope attribute



Scripsit JD:

Is the <th> scope attribute needed for simple tables?

No, but it doesn't hurt, and it may be useful for markup documentation: anyone (like you some years later) reading the HTML source alone, even without understanding the natural language in it, will immediately see that the cell is a header for a column or for a row.

For example,
will the following be clear for a wide range of visitors?

<table>
<tr><th>Make</th><th>Year</th></tr>
<tr><td>Ford </td><td>1987</td></tr>
<tr><td>Audi </td><td>2000</td></tr>
</table>

Or should I do:

<table>
<tr><th scope="col">Make</th><th scope="col">Year</th></tr>
<tr><td>Ford </td><td>1987</td></tr>
<tr><td>Audi </td><td>2000</td></tr>
</table>

Adding the scope attribute isn't very important in a case like this, but it is good practice.

It is more important to consider the accessibility of the table as a whole. How does it relate to text? What does it really mean? A person using a speech browser will be in a more difficult situation, since he does not see the table as a whole or its visual association with anything.

Using <caption>, or maybe explanatory text before the table, or even both is generally useful for a data table. If you think that the meaning and purpose is self-evident from merely looking at the table, then you might consider using the summary="..." attribute to explain them to a user who cannot look at the table.

--
Jukka K. Korpela ("Yucca")
http://www.cs.tut.fi/~jkorpela/

.



Relevant Pages

  • Re: Add text to begining of cells within a range based on specified criteria
    ... a cell based on the contents of another cell and then I need to add ... Communication 1.1 Students engage in conversations, ... Cultures 2.1 Students demonstrate an understanding of the relationship ... I need to find cells with "STANDARDS FOR FOREIGN LANGUAGE LEARNING" i ...
    (microsoft.public.excel)
  • Re: Add text to begining of cells within a range based on specified criteria
    ... another cell and then I need to add ... Communication 1.1 Students engage in conversations, ... Cultures 2.1 Students demonstrate an understanding of the relationship ... I need to find cells with "STANDARDS FOR FOREIGN LANGUAGE LEARNING" i ...
    (microsoft.public.excel.misc)
  • Re: #Value! Error in Nested IF Function
    ... My understanding of if functions are: ... But it is important to understand that the use of IFfunctions is not limited to this nested form. ... then leave the cell blank. ... the sell and buy conditions are not mutually exclusive. ...
    (microsoft.public.excel.newusers)
  • Re: Simple Stock Control Sheet
    ... I use Excel 2003. ... I'm not an Excel whiz by any means, but if my understanding is correct ... I'm understanding that you may want to be able to update the totals in ... Okay so here's what forumula I would place in cell D3 for example: ...
    (microsoft.public.excel.newusers)
  • Re: VLOOKUP is making mwe Crazy!
    ... understandably) that ITEMS are in Column B and COST in Column C. ... In Cell D1, you can enter the item name ... >>Hi i just started off with VLOOKUP function but it doesn't seem to work ... >>want ot have the basic understanding of how it functions? ...
    (microsoft.public.excel)

Loading