muruga
muruga

Reputation: 2122

html table format

I want to be able to type inside the table without having it expanded when the text reaches the edge. Instead, I want the width to be fixed so that the text automatically goes on to the next line every time it reaches the end.

<table width='100%' align='center' cellpadding='2' cellspacing='2' border='2' style='table-layout:fixed';>
<tr>
<td align='center'>Part Number</td>
<td align='center'>NSN</td>
<td align='center'>Description</td>
</tr>
<tr>
<td align='center'>0593500 00000000000000 55050000 22222</td>
<td align='center'>NULL</td>
<td align='center'>STONEGUARD</td>
</tr>
</table>

Upvotes: 1

Views: 138

Answers (1)

Rashmi Kant Shrivastwa
Rashmi Kant Shrivastwa

Reputation: 1167

you may try this

<table style="table-layout: fixed">
<tr><td style="word-wrap:break-word">word word word</td></tr>
</table>

Upvotes: 2

Related Questions