Why does overflow:hidden not work in a <td>?
Posted
by mike
on Stack Overflow
See other posts from Stack Overflow
or by mike
Published on 2009-02-04T01:06:05Z
Indexed on
2010/04/30
1:37 UTC
Read the original article
Hit count: 267
I've got a table cell that I would always like to be a particular width. However, it doesn't work with large strings of unspaced text. Here's a test case:
<html><body>
<table><tbody><tr>
<td style="border: solid green 1px; width:200px; overflow:hidden;">
This_is_a_terrible_example_of_thinking_outside_the_box.
</td>
</tr></tbody></table>
</body></html>
How do I get the text to be cut off at the edge of the box, rather than having the box expanded?
© Stack Overflow or respective owner