469,286 Members | 2,425 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,286 developers. It's quick & easy.

Clipping table cells

I'm trying to get table cells to clip content rather than wrapping.
It has been suggested to use:

td.clipped {
width: 5em;
overflow: hidden;
white-space: nowrap;
}
However, that doesn't work in either Firefox or IE. If I set
display:block, it sort of works in Firefox but IE (which is the target
for this intranet app) doesn't play the game at all.

table-layout:fixed doesn't seem to help either - or do I need to set
the widht of each column to make it work?

How can I force IE to clip table cells?
--
Rob

Jun 26 '07 #1
1 2540
On Jun 26, 2:50 pm, RobG <r...@iinet.net.auwrote:
I'm trying to get table cells to clip content rather than wrapping.
It has been suggested to use:

td.clipped {
width: 5em;
overflow: hidden;
white-space: nowrap;
}

However, that doesn't work in either Firefox or IE. If I set
display:block, it sort of works in Firefox but IE (which is the target
for this intranet app) doesn't play the game at all.

table-layout:fixed doesn't seem to help either - or do I need to set
the widht of each column to make it work?

How can I force IE to clip table cells?
I think I've go it: set table-layout:fixed, set a width for the table
and in IE, replace all spaces with &nbsp;

How'd I go? Amazing how you can beat your head against a wall for
quite some time, then within a few minutes of posting - the answer
appears.

--
Rob

Jun 26 '07 #2

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

4 posts views Thread by jeffsal | last post: by
1 post views Thread by cotton_gear | last post: by
3 posts views Thread by Phil Rutter | last post: by
7 posts views Thread by Shawn B. | last post: by
2 posts views Thread by Pugi! | last post: by
7 posts views Thread by Kamal | last post: by
1 post views Thread by CARIGAR | last post: by
reply views Thread by zhoujie | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.