HTML and CSS Reference
In-Depth Information
Cells always span downward and to the right. To create a cell that spans several columns,
you add the colspan attribute to the leftmost cell in the span. For cells that span rows,
you add rowspan to the topmost cell.
The following input and output example shows a cell that spans multiple rows (the cell
with the word Piston in it). Figure 10.23 shows the result.
<!DOCTYPE html>
<title> Ring Clearance </title>
<table border=“1” summary=“ring clearance”>
<th colspan=“2”> </th>
<th> Ring <br />
Clearance </th>
<tr align=“center”>
<th rowspan=“2”> Piston </th>
<th> Upper </th>
<td> 3mm </td>
<tr align=“center”>
<th> Lower </th>
<td> 3.2mm </td>
FIGURE 10.23
Cells that span
multiple rows and
Search WWH ::

Custom Search