Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8" />
<title>Table with colspan and rowspan</title>
<link rel="stylesheet" href="css/table-with-colspan-rowspan.css" />
</head>
<body>
<table>
<caption>TV Schedule</caption>
<thead> <!-- table head -->
<tr>
<th scope="rowgroup">Time</th>
<th scope="col">Mon</th>
<th scope="col">Tue</th>
<th scope="col">Wed</th>
</tr>
</thead>
<tbody> <!-- table body -->
<tr>
<th scope="row">8 pm</th>
<td>Staring Contest</td>
<td colspan="2">Celebrity Hoedown</td>
</tr>
<tr>
<th scope="row">9 pm</th>
<td>Hardy, Har, Har</td>
<td>What's for Lunch?</td>
<td rowspan="2">Screamfest Movie of the Weak</td>
</tr>
<tr>
<th scope="row">10 pm</th>
<td>Healers, Wheelers &amp; Dealers</td>
<td>It's a Crime</td>
</tr>
</tbody>
</table>
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.