<table>
<tr>
<td>
<span style="width:180px; overflow:hidden; white-space:nowrap;text-overflow:ellipsis;" title="中间的值">
中间内容
</span>
</td>
</tr>
</table>
width 设定长度为多少的时候变为“...”
很实用 不用写复杂的代码了
<table>
<tr>
<td>
<span style="width:180px; overflow:hidden; white-space:nowrap;text-overflow:ellipsis;" title="中间的值">
中间内容
</span>
</td>
</tr>
</table>
width 设定长度为多少的时候变为“...”
很实用 不用写复杂的代码了