I'm trying to achieve a fluid width table where text in the cells isn't allowed to flow onto another line and will use text-overflow:ellipsis
when it is too long to fit.
I tried the following test:
HTML:
<table>
<tr>
<td>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec feugiat placerat risus. Maecenas lectus orci, commodo id varius ac, vulputate eget elit. Nunc laoreet feugiat aliquet.</td>
</tr>
</table>
CSS:
table { width: 100%; }
td {
overflow: hidden;
white-space: nowrap;
text-overflow: ellipsis; }
But as you can see in the fiddle below, the ellipsis doesn't work:
Is there a solution?