Previous Message
Next Message

Giving Layout to IE causing larger margin

Sent by Gunlaug_Sørtun on 14 April 2006 04:04


Richard Grevers wrote:
> A site redesign was proceding nicely (and amazingly hack-free) until 
> I tried to clear a float, which triggered haslayout bugs in IE.
> 
> I figured that giving layout to #content (via height:1px in a 
> conditional comment) should fix it, and indeed it has fixed the 
> peekaboo aspect of it, but IE has now applied a right margin or 
> padding or something of around 100px on #content. (it is supposed to
>  have a margin of 1.5em)

....but will also adjust the entire #content to the available width.
There's a right-floating element - an 120px wide image - before the
#content in your source-code, and that is affecting the following line-up.

> The page with the float is http://new.paen.net/de/team.mv (also its 
> english equivalent). The other test pages (clients and index) also 
> show the problem.

1: correct the inline-style to...
<img src="/images/sub_reflection_de.png" alt="All Languages"
style="float:right; margin-bottom: -100px;" />
....for all browsers - and apply a CSS class for this instead of that
inline-style.
Be aware of the fact that I've used a margin-bottom that is /much/
larger than the height of the floating image. It doesn't show or hurt,
as it only makes that image take up /no space at all/ from the browsers'
point of view.

2: add...
#content {clear: both;}
....for all browsers.

= line-up the same in all browsers I care to test in.

regards
	Georg
-- 
http://www.gunlaug.no
______________________________________________________________________
css-discuss [EMAIL-REMOVED]]
http://www.css-discuss.org/mailman/listinfo/css-d
IE7b2 testing hub -- http://css-discuss.incutio.com/?page=IE7
List wiki/FAQ -- http://css-discuss.incutio.com/
Supported by evolt.org -- http://www.evolt.org/help_support_evolt/
Previous Message
Next Message

Message thread: