Latest web development tutorials

HTML td rowspan attributes

HTML td tag Reference Manual HTML <td> tag

Examples

The following table contains a HTML spans two rows of a table cell:

<table border="1">
<tr>
<th>Month</th>
<th>Savings</th>
<th>Savings for holiday!</th>
</tr>
<tr>
<td>January</td>
<td>$100</td>
<td rowspan="2">$50</td>
</tr>
<tr>
<td>February</td>
<td>$80</td>
</tr>
</table>

try it"
(For more examples, see the bottom of the page)

Browser Support

Internet ExplorerFirefoxOperaGoogle ChromeSafari

All major browsers support rowspan attribute.

Note: Only Firefox and Opera support rowspan = "0", this value has a special meaning (see below "property values" table).


Definition and Usage

rowspan attribute defines the number of cell lines should crossings.


Differences between HTML 4.01 and HTML5

no.


grammar

<td rowspan="number">

Property Value

描述
number 规定单元格应该横跨的行数。注意: rowspan="0" 告知浏览器使单元格横跨到表格组件中的最后一个行(thead、tbody 或 tfoot)。


Examples

More examples

rowspan = "0" Use
This example only applies to Firefox and Opera browsers, example demonstrates rowspan = "0" to use.


HTML td tag Reference Manual HTML <td> tag