On Mon, 14 Jan 2008 18:20:04 -0500, Randal Rust wrote:
> I have always used the good old method of a spacer DIV like this to clear 
> floats:
>
> <div class="spacer"></div>
>
> div.spacer { clear: both; }
>
> Problem is, the ad agency that I work with keeps creating these complex 
> layouts where
> using that convention just won't work. The reason is that in IE the spacer 
> DIV has a
> height of about 10 pixels. In Firefox, etc. you can get around it by setting 
> the height
> to 0px, but that doesn't work in IE 6 and 7.
>

Philippe and Lisa have given you some alternatives. But you can
continue to use your preferred method - a spacer DIV - simply
by adding an empty comment inside the DIV, like this:

  <div class="spacer"><!-- --></div>

A font-size of 1px may help some other browsers, IIRC -
however, I don't remember the details.

Cordially,
David
--

______________________________________________________________________
css-discuss [EMAIL PROTECTED]
http://www.css-discuss.org/mailman/listinfo/css-d
List wiki/FAQ -- http://css-discuss.incutio.com/
List policies -- http://css-discuss.org/policies.html
Supported by evolt.org -- http://www.evolt.org/help_support_evolt/

Reply via email to