WebProWorld Part of WebProNews.com
Page One Link To Us Edit Profile Private Messages Archives FAQ RSS Feeds  
 

Go Back   WebProWorld > Site Design > Graphics & Design Discussion Forum > Accessibility and Usability Forum
Subscribe to the Newsletter FREE!


Register FAQ Members List Calendar Arcade Chatbox Mark Forums Read

Accessibility and Usability Forum Discuss topics related to website accessibility and usability. Subjects include; testing techniques, tutorials, guidelines and legal issues.

Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 09-22-2003, 09:17 AM
WebProWorld Member
 

Join Date: Jul 2003
Posts: 27
cyberRobot RepRank 0
Default Making Tables Accessible

I'm currently reading a book on web accessability and I have a few questions about making tables accessable.

According to the book, in order to make a simple table accessable you need to use the th tag or the scope attribute. Why wouldn't you use both? Is the scope attribute supported by all screen readers?

For Example --
Code:
<table>
   <tr>
      <td></td>
      <th scope="col">Apples</th>
      <th scope="col">Oranges</th>
   </tr>
   <tr>
      <th scope="row">Mike</th>
      <td>5</td>
      <td>8</td>
   </tr>
   ...
</table>
Thanks for your help!
Reply With Quote
  #2 (permalink)  
Old 09-22-2003, 12:15 PM
Webnauts's Avatar
WebProWorld 1,000+ Club
 

Join Date: Aug 2003
Location: Worldwide
Posts: 7,399
Webnauts RepRank 3Webnauts RepRank 3
Default

I would suggest you to have a look here:

http://www.webaim.org/tutorials/tables

http://diveintoaccessibility.org/day...ent_first.html

http://www.mcu.org.uk/articles/tables.html

http://diveintoaccessibility.org/day...e_headers.html

A great tool:
Accessible Table Builder: http://www.accessify.com/tools-and-wizards/accessible-table-builder_step1.asp

If you then still have questions, please feel free to post them.
Reply With Quote
  #3 (permalink)  
Old 09-23-2003, 08:21 AM
WebProWorld Member
 

Join Date: Jul 2003
Posts: 27
cyberRobot RepRank 0
Default

None of those links really helped.

Do the majority of the screen readers/speaking browsers support <th> tag and the scope attribute? If some don't support the scope attribute then the tables should always have a <th> tag. (And vice-versa) So if that's the case, shouldn't we always use both the <th> tag and the scope attribute?

Note: I know very little about screen readers/speaking browsers, so I have no idea what code the majority of them support.
Reply With Quote
  #4 (permalink)  
Old 09-23-2003, 02:10 PM
ScottNorton's Avatar
WebProWorld Member
 

Join Date: Jul 2003
Location: Arlington, VA
Posts: 26
ScottNorton RepRank 0
Default <th> tags and scope for accessible tables

If you have a very simple table and mark your row and column headings with <th>, you don't need the scope attributes. In your sample table, the <th>'s will do their job just fine and as the user navigates through the table, JAWS will read the row or column heading (whichever one changes).

Scope is useful in two cases:
  1. Complex tables, where an interior <th> could be a row or a column heading
  2. <td> headings.

A <td> heading sounds like a contradiction in terms, but is really useful and sensible. The W3C accessibility pages use an example sort of like this:

Code:
Drink    Senators    Representatives
-------    ----------    -----------------
Coffee      23           95
Water       18           27
Tea            5            18
In that table, the drink names are data and should be marked with a <td> tag, but they are also the heading for the row, so that if you went down the Senators column, your would want the browser to read "Senators. Coffee, 23. Water, 18. Tea, 5." <td scope="col"> makes that happen.
__________________
Scott Norton
DTI Associates, Inc.
SNorton@DTIHQ.com
or Norton@ACM.org
Reply With Quote
  #5 (permalink)  
Old 09-23-2003, 02:47 PM
WebProWorld Member
 

Join Date: Jul 2003
Posts: 27
cyberRobot RepRank 0
Default Re: <th> tags and scope for accessible tables

Quote:
Originally Posted by ScottNorton
A <td> heading sounds like a contradiction in terms, but is really useful and sensible. The W3C accessibility pages use an example sort of like this:

Code:
Drink    Senators    Representatives
-------    ----------    -----------------
Coffee      23           95
Water       18           27
Tea            5            18
In that table, the drink names are data and should be marked with a <td> tag, but they are also the heading for the row, so that if you went down the Senators column, your would want the browser to read "Senators. Coffee, 23. Water, 18. Tea, 5." <td scope="col"> makes that happen.
Thanks, that was very helpful. Let me just make sure I'm getting this. Would the code for the example you gave look something like this:

Code:
...
   <tr>
      <th>Drink</th>
      <th>Senators</th>
      <th>Representatives</th>
   </tr>
   <tr>
      <td scope="row">Coffee</td>
      <td>23</td>
      <td>95</td>
   </tr>
...
Reply With Quote
  #6 (permalink)  
Old 09-23-2003, 03:49 PM
WebProWorld Member
 

Join Date: Aug 2003
Location: Myrtle Beach, SC
Posts: 72
luvdavy RepRank 0
Default another question

While we're talking tables, I was trying to use some kind of html verifyer the other day and it keeps demanding me to do a table "summary". What in the world is that?

Jan
Reply With Quote
  #7 (permalink)  
Old 09-23-2003, 04:15 PM
WebProWorld Member
 

Join Date: Jul 2003
Posts: 27
cyberRobot RepRank 0
Default Re: another question

Quote:
Originally Posted by luvdavy
While we're talking tables, I was trying to use some kind of html verifyer the other day and it keeps demanding me to do a table "summary". What in the world is that?

Jan
The summary attribute allows you to describe the table's purpose.

Code:
<table summary="Table contains the calendar for September 2003">
If the table is used for layout purposes, it's good to keep the summary short. (We use "Layout Table")
Reply With Quote
  #8 (permalink)  
Old 09-23-2003, 05:29 PM
WebProWorld Member
 

Join Date: Aug 2003
Location: Myrtle Beach, SC
Posts: 72
luvdavy RepRank 0
Default

Now why would I want to explain what a table was for?
Who would see it? A search engine spider supposedly skips all the html. I don't get it.

Jan
Reply With Quote
  #9 (permalink)  
Old 09-23-2003, 08:52 PM
WebProWorld Member
 

Join Date: Jul 2003
Posts: 27
cyberRobot RepRank 0
Default

Quote:
Originally Posted by luvdavy
Now why would I want to explain what a table was for?
Who would see it? A search engine spider supposedly skips all the html. I don't get it.

Jan
What scanner were you using? Were you scanning for web accessibility? The summary attribute is used to help people, who use screen readers, understand your table better.

From what I understand, the summary attribute is optional to be HTML compliant.
Reply With Quote
  #10 (permalink)  
Old 09-24-2003, 02:13 AM
WebProWorld Member
 

Join Date: Aug 2003
Location: Myrtle Beach, SC
Posts: 72
luvdavy RepRank 0
Default

It was an HTML verifyer called HTML Kit. I didn't think about it being there for readers and such.

I've never seen a table on a webpage that had something like that summary attribute in it. Oh well.

Jan
Reply With Quote
  #11 (permalink)  
Old 09-24-2003, 07:23 AM
Webnauts's Avatar
WebProWorld 1,000+ Club
 

Join Date: Aug 2003
Location: Worldwide
Posts: 7,399
Webnauts RepRank 3Webnauts RepRank 3
Default

Quote:
Originally Posted by luvdavy
It was an HTML verifyer called HTML Kit. I didn't think about it being there for readers and such.

I've never seen a table on a webpage that had something like that summary attribute in it. Oh well.

Jan
I use the summary attribute on my web site!
Reply With Quote
  #12 (permalink)  
Old 09-24-2003, 08:26 AM
WebProWorld Member
 

Join Date: Jul 2003
Posts: 27
cyberRobot RepRank 0
Default

Quote:
Originally Posted by luvdavy
It was an HTML verifyer called HTML Kit. I didn't think about it being there for readers and such.

I've never seen a table on a webpage that had something like that summary attribute in it. Oh well.

Jan
In order to see the summary text, you'll need to go into the source code for a website. Of couse, not all websites use the summary attribute. (Most of them probably don't)
Reply With Quote
  #13 (permalink)  
Old 09-24-2003, 05:01 PM
WebProWorld Member
 

Join Date: Aug 2003
Location: Myrtle Beach, SC
Posts: 72
luvdavy RepRank 0
Default

[quote="cyberRobot
In order to see the summary text, you'll need to go into the source code for a website. Of couse, not all websites use the summary attribute. (Most of them probably don't)[/quote]

Before I finally memorized and learned to make my tables, I viewed the source & copied and pasted others all the time. I honestly never saw that summary thing anywhere. I also don't think that Webmonkey mentioned it either. Maybe it's something they just started doing in the last year or so....

Since I do all my own html coding, I probably miss things that people who used editors know about, I guess.

Jan
Reply With Quote
  #14 (permalink)  
Old 09-24-2003, 09:16 PM
Webnauts's Avatar
WebProWorld 1,000+ Club
 

Join Date: Aug 2003
Location: Worldwide
Posts: 7,399
Webnauts RepRank 3Webnauts RepRank 3
Default About "Summary" attribute

Use "SUMMARY" attribute for your tables.

When a table is more complicated, Web authors are encouraged to use the summary attribute of the TABLE element. This, like the longdesc attribute for images, is not represented visually. It is rendered from the HTML code by assistive technology like screen readers and talking browsers.

The summary attribute should contain, as its name suggests, a summary of what the table presents.

With a summary, a blind person using a screen reader (which supports the summary attribute) will have an overview of the table before he starts to read it.
Reply With Quote
  #15 (permalink)  
Old 09-25-2003, 04:39 PM
WebProWorld Member
 

Join Date: Jul 2003
Posts: 27
cyberRobot RepRank 0
Default Re: About "Summary" attribute

Quote:
Originally Posted by Webnauts
Use "SUMMARY" attribute for your tables.
That seems a bit demanding, but I would also recommend using the summary attribute. One question for whoever knows the answer. Does providing a summary for every layout table get annoying for people using screen readers. ("Layout Table, Layout Table, Layout Table...")

I noticed that www.webaim.org doesn't use the summary attribute for all their tables. (They do use it for some, which are not layout tables.)

Quote:
Originally Posted by Webnauts
When a table is more complicated, Web authors are encouraged to use the summary attribute of the TABLE element. This, like the longdesc attribute for images, is not represented visually. It is rendered from the HTML code by assistive technology like screen readers and talking browsers.

The summary attribute should contain, as its name suggests, a summary of what the table presents.

With a summary, a blind person using a screen reader (which supports the summary attribute) will have an overview of the table before he starts to read it.
According to the book I'm reading "Constructing Accessessible Web Sites", they highly recommend using the summary attribute, but they also mention that they are "not sufficiently supported by major assistive technology manufacturers to warrent recommendation".

Note: The reason why they say this is so web developers don't use the summary attribute as an alternative to making their tables complient. (Using the th tag and scope/headers attributes)

So maybe that has an effect on why web developers don't use the summary tag. (Lack of support?)
Reply With Quote
  #16 (permalink)  
Old 09-25-2003, 04:45 PM
WebProWorld Member
 

Join Date: Jul 2003
Posts: 27
cyberRobot RepRank 0
Default Re: <th> tags and scope for accessible tables

I'm beginning to think that my question got lost does anyone know if my code is correct (for accessibility) for ScottNorton's example?


Quote:
Originally Posted by ScottNorton
Drink Senators Representatives
------- -------- ---------------
Coffee 23 95
Water 18 27
Tea 5 18
Quote:
Originally Posted by cyberRobot
Code:
...
   <tr>
      <th>Drink</th>
      <th>Senators</th>
      <th>Representatives</th>
   </tr>
   <tr>
      <td scope="row">Coffee</td>
      <td>23</td>
      <td>95</td>
   </tr>
...
Reply With Quote
  #17 (permalink)  
Old 09-25-2003, 08:32 PM
Webnauts's Avatar
WebProWorld 1,000+ Club
 

Join Date: Aug 2003
Location: Worldwide
Posts: 7,399
Webnauts RepRank 3Webnauts RepRank 3
Default Re: <th> tags and scope for accessible tables

Quote:
Originally Posted by cyberRobot
I'm beginning to think that my question got lost does anyone know if my code is correct (for accessibility) for ScottNorton's example?


Quote:
Originally Posted by ScottNorton
Drink Senators Representatives
------- -------- ---------------
Coffee 23 95
Water 18 27
Tea 5 18
Quote:
Originally Posted by cyberRobot
Code:
...
   <tr>
      <th>Drink</th>
      <th>Senators</th>
      <th>Representatives</th>
   </tr>
   <tr>
      <td scope="row">Coffee</td>
      <td>23</td>
      <td>95</td>
   </tr>
...
I agree with CyberRobot!
Reply With Quote
  #18 (permalink)  
Old 09-27-2003, 05:23 PM
zbatia's Avatar
WebProWorld Pro
 

Join Date: Jul 2003
Location: Baltimore, MD
Posts: 128
zbatia RepRank -1
Default

luvdavy wrote:
I've never seen a table on a webpage that had something like that summary attribute in it ...
========================================
luvdavy,
I use SUMMARY="table name that is another keyword for search engine"
In fact, my summary parameter helps me to manage the complicated nested tables.
Example:

<table width="785px" cellpading="0" cellspacing="0" border="0" summary="EXTERNAL BORDER TABLE CERTIFICATION COURSES">
...........................
</table>
(which indicates the end of this table)
There are 1000 opinions about how search engines work, but I am sure that the only search engine developers really know how. Therefore, along with the table name for manageabilty I use some of the keywords. So, SUMMARY parameter is very useful.

I use the cseHTML Professional Validator that is "must have" for serious web designer.
__________________
The Cyber Teacher
http://www.rtek2000.com
http://www.800-webdesign.com/web-master-links.html -Free Web Master's Resources
_________________
Reply With Quote
  #19 (permalink)  
Old 09-27-2003, 05:29 PM
Webnauts's Avatar
WebProWorld 1,000+ Club
 

Join Date: Aug 2003
Location: Worldwide
Posts: 7,399
Webnauts RepRank 3Webnauts RepRank 3
Default

Quote:
Originally Posted by zbatia
luvdavy wrote:
I've never seen a table on a webpage that had something like that summary attribute in it ...
========================================
luvdavy,
I use SUMMARY="table name that is another keyword for search engine"
In fact, my summary parameter helps me to manage the complicated nested tables.
Example:

<table width="785px" cellpading="0" cellspacing="0" border="0" summary="EXTERNAL BORDER TABLE CERTIFICATION COURSES">
...........................
</table>
(which indicates the end of this table)
There are 1000 opinions about how search engines work, but I am sure that the only search engine developers really know how. Therefore, along with the table name for manageabilty I use some of the keywords. So, SUMMARY parameter is very useful.

I use the cseHTML Professional Validator that is "must have" for serious web designer.
Great post. Besides I use and resell myself the CSE HTML Validator.
Reply With Quote
  #20 (permalink)  
Old 11-03-2003, 02:24 PM
ScottNorton's Avatar
WebProWorld Member
 

Join Date: Jul 2003
Location: Arlington, VA
Posts: 26
ScottNorton RepRank 0
Default Re: <th> tags and scope for accessible tables

Quote:
Originally Posted by cyberRobot
I'm beginning to think that my question got lost does anyone know if my code is correct (for accessibility) for ScottNorton's example?


Quote:
Originally Posted by ScottNorton
Drink Senators Representatives
------- -------- ---------------
Coffee 23 95
Water 18 27
Tea 5 18
Quote:
Originally Posted by cyberRobot
Code:
...
   <tr>
      <th>Drink</th>
      <th>Senators</th>
      <th>Representatives</th>
   </tr>
   <tr>
      <td scope="row">Coffee</td>
      <td>23</td>
      <td>95</td>
   </tr>
...
Oops. I'd stopped watching this thread.

Yes, your code is correct.
__________________
Scott Norton
DTI Associates, Inc.
SNorton@DTIHQ.com
or Norton@ACM.org
Reply With Quote
  #21 (permalink)  
Old 11-03-2003, 02:48 PM
ScottNorton's Avatar
WebProWorld Member
 

Join Date: Jul 2003
Location: Arlington, VA
Posts: 26
ScottNorton RepRank 0
Default Table summary: For users, not for programmers.

Quote:
Originally Posted by zbatia
I use SUMMARY="table name that is another keyword for search engine"
In fact, my summary parameter helps me to manage the complicated nested tables.
Example:

Code:
<table width="785px" cellpading="0" cellspacing="0" border="0" summary="EXTERNAL BORDER TABLE CERTIFICATION COURSES">
...........................
</table>
(which indicates the end of this table)
There are 1000 opinions about how search engines work, but I am sure that the only search engine developers really know how. Therefore, along with the table name for manageabilty I use some of the keywords. So, SUMMARY parameter is very useful.

I use the cseHTML Professional Validator that is "must have" for serious web designer.
While its good to realize that the table summary is part of your page's content, and so might contribute to its indexing, the primary purpose of the summary attribute is to summarize the table so that someone using assistive technology can be oriented to the table's purpose before decending into the individual cell