W3C home > Mailing lists > Public > www-style@w3.org > July 2004

Browser Compatibility issues

From: Jason Davidson <jdavidson@zworg.com>
Date: Mon, 19 Jul 2004 09:30:46 -0700
To: www-style@w3.org
Message-id: <698.1090254646@zworg.com>

Hi, im having a problem with a real simple task. :) (nothing unusual
All i would like to do , is clip some text should it be too long.  this
is remarkable simple if you know the exact width you would like to
clip, however, i would like to use relative sizing, and this is
presenting a problem in IE, gecko browsers work perfectly.  the problem
lies in this, 
i have a width: expression(this.parentNode.clientWidth-5) css attribute,
this is for IE to calculate the size of the element im applying this
too, which as expected should be 5 px's less then its parent.  The
problem ive found, is if the parent, or any parents in the heiarchy
have a relative size constraint, IE crashes miserably on resizing.  Any
possible solutions to this is readily welcome.. here is an example of
the css i would use, this isnt it exactly, but this should at least
present the problem.

div.clipCell {
   width: expression(this.parentNode.clientWidth-5);
   white-space: nowrap;
   overflow: hidden;
   text-overflow: ellipsis;
   cursor: pointer;

of coarse, what works in gecko brorswers wonderfully, is width: 100% ..
curse you IE !!

Received on Monday, 19 July 2004 12:33:18 UTC

This archive was generated by hypermail 2.3.1 : Monday, 2 May 2016 14:27:14 UTC