Paul D. Waite Paul D. Waite - 10 months ago 41
HTML Question

What’s the correct scope value to use for an HTML <th> table cell than spans several columns?

Say you’ve got an HTML table, with a

cell that spans several columns, e.g.

<th colspan="3" scope="?">Scores</th>
<!-- ...more headings here... -->
<th scope="col">English</th>
<th scope="col">Maths</th>
<th scope="col">Science</th>
<!-- ...more sub-headings here... -->
<!-- ...more cells here... -->

What’s the correct value for the scope attribute for the spanning header cell?
seems incorrect as it’s heading several columns, but
does’t seem right if I don’t actually have any


According to the second example table in the HTML spec, it’s colgroup, despite the lack of colgroup tags.