HTML <td> nowrapAttribute

HTML td 标签参考手册HTML <td> Tag

Examples

A table cell with the nowrap attribute:

<table border="1">
<tr>
<th>Poem</th>
<th>Poem</th>
</tr>
<tr>
<td nowrap>Never increase, beyond what is necessary, the number of entities required to explain anything</td>
<td>Never increase, beyond what is necessary, the number of entities required to explain anything</td>
</tr>
</table>

Try it yourself »

Browser Support

Internet ExplorerFirefoxOperaGoogle ChromeSafari

All major browsers support the nowrap attribute.


Definition and Usage

HTML5 does not support the <td> nowrap attribute. Use CSS instead.

In HTML 4.01, the nowrap attribute of <td>is deprecated.。

The nowrap attribute is a boolean attribute.

The nowrap attribute specifies that the content of a table cell should not wrap.


Compatibility Notes

In HTML 4.01, the nowrap attribute of <td> is deprecated. Use CSS instead.

CSS syntax: <td style="white-space: nowrap">

CSS Example: No wrapping in table cells

In our CSS tutorial, you can find more aboutthe white-space propertyin detail.


Differences Between HTML and XHTML

In XHTML, attribute minimization is forbidden, and the nowrap attribute must be defined as <td nowrap="nowrap">.


Syntax

<td nowrap>


HTML td 标签参考手册HTML <td> Tag Other Extensions