Created
March 9, 2012 15:29
-
-
Save ringmaster/2007022 to your computer and use it in GitHub Desktop.
Table overflow
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Table overflow | |
*/ | |
#tbl { | |
width: 300px; | |
table-layout: fixed; | |
} | |
#tbl td { | |
overflow: hidden; | |
width: 100px; | |
white-space: nowrap; | |
border: 1px solid black; | |
vertical-align: top; | |
height: 1em; /* Only makes the cells bigger, doesn't constrain */ | |
} | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<table id="tbl"> | |
<tr> | |
<td>This is somewhat wide data</td> | |
<td>This is somewhat wide data<br/> | |
With a second line</td> | |
<td>This is somewhat wide data</td> | |
</tr> | |
<tr> | |
<td>This is somewhat wide data</td> | |
<td>This is somewhat wide data</td> | |
<td>This is somewhat wide data</td> | |
</tr> | |
</table> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{"view":"separate","seethrough":"","prefixfree":"1","page":"all"} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment