Latest web development tutorials

HTML td height property

HTML td tag Reference Manual HTML <td> tag

Examples

Two with predefined height table cells:

<table border="1">
<tr>
<th>Month</th>
<th>Savings</th>
</tr>
<tr>
<td height="100">January</td>
<td height="100">$100</td>
</tr>
<tr>
<td>February</td>
<td>$80</td>
</tr>
</table>

try it"

Browser Support

Internet ExplorerFirefoxOperaGoogle ChromeSafari

All major browsers support height attributes.


Definition and Usage

HTML5 does not support the <td> height property. Use CSS instead.

In HTML 4.01, <td> height property is obsolete .

height attribute specifies the height of a cell.

Typically, the space occupied by the cell is that it requires the contents of display space. height property is used to set up predefined cell height.


Compatibility Notes

In HTML 4.01, <td> height of the property has been abandoned. Use CSS instead.

CSS Syntax: <td style = "height: 100px">

CSS Example: Set the table height of the cell

In our CSS tutorial you can find more information about the height property detail.


grammar

<td height="pixels|%">

Property Value

描述
pixels 设置以像素计的高度值(比如 height="50")。
% 设置以包含元素百分比计的高度值(比如 height="50%")。


HTML td tag Reference Manual HTML <td> tag