Try using max-width
instead of width
, the table will still calculate the width automatically.
Works even in ie11
(with ie8 compatibility mode).
td.max-width-50 {_x000D_
border: 1px solid black;_x000D_
max-width: 50px;_x000D_
overflow: hidden;_x000D_
text-overflow: ellipsis;_x000D_
white-space: nowrap;_x000D_
}
_x000D_
<table>_x000D_
<tbody>_x000D_
<tr>_x000D_
<td class="max-width-50">Hello Stack Overflow</td>_x000D_
</tr>_x000D_
<tr>_x000D_
<td>Hello Stack Overflow</td>_x000D_
</tr>_x000D_
<tr>_x000D_
<td>Hello Stack Overflow</td>_x000D_
</tr>_x000D_
</tbody>_x000D_
</table>
_x000D_