Spanning Rows


#1

in the example that appears in “SPANNING ROWS” :

for saturday and sunday, it is not better use <th scopete = “col”

<table>
  <tr>                         
 <th></th>
    <th>Saturday</th><th scopet="col">Saturday</th>
     <th>Sunday</th><th scopet="col">Sunday</th>
  </tr>
  <tr>
    <th>Morning</th>
    <td rowspan="2">Work</td>
    <td rowspan="3">Relax</td>
  </tr>
  <tr>
    <th>Afternoon</th>
  </tr>
  <tr>
    <th>Evening</th>
    <td>Dinner</td>
  </tr>
</table>

#2

As far as I know there is only one attribute… scope relating to columns and rows.

What lesson is this? Please post a link to the exact exercise. Thanks.


#3

yes, thanks mtf, it’s my mistake.

what I mean, is that in the example, does not refer to the scope attribute in the headers of the columns


#5

https://www.codecademy.com/courses/learn-html-tables/lessons/tables/exercises/rowspan?action=lesson_resume&course_redirect=learn-html


#6

scope applies to any TH whether column header of row header.

<th scope="col"><th>

<th scope="row"></th>

See this post for a simple example…

What's the difference between <th> and <thead>?


#7

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.