|
|
#1 (permalink) |
|
Registered User
Comfy Contributor
Joined in Aug 2005
Lives in Netherlands
Hosted on Pass48
124 posts
Gave thanks: 0
Thanked 0 times
|
[html] Cutting words of in tables to prevent width from expanding?
Is it possible to make words cut themself off to prevent the cell from expanding?
I just got a example table like this : Code:
<table width="10" border="1">
<tr>
<td>
blablablabalblablabla
</td>
</tr>
</table>
Code:
<table width="10" border="1">
<tr>
<td>
b l a b lablabalblablabla
</td>
</tr>
</table>
Anybody know a solution to it? Thnx! |
|
|
|
|
|
#2 (permalink) |
|
rocks your socks.
Resident.
Joined in Mar 2004
Lives in fear of Obama.
Hosted on Pass 7
13,170 posts
Gave thanks: 8
Thanked 35 times
|
Might want to google some stuff on wordwrap. I know you can prevent it with nowrap=nowrap, but I'm not sure how to do the opposite. Essentially, omitting the tag is supposed to cause wordwrap by default.
|
|
|
|
|
|
#3 (permalink) |
|
Registered User
Comfy Contributor
Joined in Aug 2005
Lives in Netherlands
Hosted on Pass48
124 posts
Gave thanks: 0
Thanked 0 times
|
Thanks, didn't know the word for it.. a quick search and I found this :
word-break: break-all; It works, in IE. Not in Firefox/Opera. So I still need a multi-browser solution. *continues search* |
|
|
|
|
|
#5 (permalink) |
|
Registered User
Comfy Contributor
Joined in Aug 2005
Lives in Netherlands
Hosted on Pass48
124 posts
Gave thanks: 0
Thanked 0 times
|
I found this :
table-layout: fixed; Doesn't wrap around words, but it does keep the table width to the specified size, only the remaining piece of the word will disappear. But I fixed it with the php function wordwrap(); Thnx for getting me on the right track =D |
|
|
|