Grouping Table Rows
You can also group table rows using three elements that define the row groups based on function. The elements include thead, tfoot, and tbody for table head, table foot, and table body, respectively (see Example 4-16).
Example 4-16. Grouping table rows
<thead><tr><th>Table Head</th><th>Table Head</th><th>Table Head</th></tr></thead><tfoot><tr><td>Table Foot</td><td>Table Foot</td><td>Table Foot</td></tfoot><tbody><tr><td>Table Body</td><td>Table Body</td><td>Table Body</td></tr></tbody></tr></table>
Browser support is more consistent for these elements. Figure 4-17 shows the results.
Figure 4-17. Grouping by row—you'll notice that I've defined the foot in the middle of the table, but the row defined as the table foot ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access