css实现不再让内容把td撑开的常用解决方法

(编辑:jimmy 日期: 2024/11/1 浏览:2)


复制代码代码如下:
<style type="text/css">
table {width:600px;table-layout:fixed;}
td {white-space:nowrap;overflow:hidden;word-break:keep-all;text-overflow:ellipsis}
</style>
<table border=1 >
<tr>
<td width="30%">dd</td>
<td>ddddddddddddddddddddddddddddddfsljdflsajufiajklsjadflkjsalkfdjdsklajdflksajflksajfdlkdsjdflksjfjldskajdflksajflskajf</td>
<td width="30%">dd</td>
</tr>
</table>