W3C home > Mailing lists > Public > www-style@w3.org > March 1998

Margin in Internet Explorer

From: Francois-Denis Gonthier <claudeg@icrdl.net>
Date: Wed, 18 Mar 1998 20:35:41 -0500 (EST)
Message-ID: <000401bd52d7$36bf60c0$815c2fce@claudeg.icrdl.net>
To: <www-style@w3.org>
This HTML/CSS code seems to cause problems to Explorer:

<html>
<head>
[...]
  div.pres { font-family: sans-serif ;
             margin-left: 8% ;
             margin-right: 8% ;
             margin-top: 2em ;                    <<
             margin-bottom: 2em ; }            << Notice those...
  div.subpres { font-family: sans-serif ;
                margin-left: 12% ;
                margin-right: 12% ; }
</head>
<body>
<table cellpadding=0 cellspacing=0>
<tr><td bgcolor=black>Left-top</td><td bgcolor=black>Top</td></tr>     <<
Don't look at that code
<tr><td bgcolor=black>Left</td><td>
<div class="pres">                                << Problem area begins...
[...]
</body>
</html>

Internet Explorer seems to be unable to display the top and bottom margin
correctly when relative values are used, but it works perfectly with 'em'
values.  Notice left and right margins are displayed perfectly.  Have
anybody noticed that and is there a more elegant way to move around this bug
? (or am I a fool ?)

Also with IE, DIV tags doesn't seem to inherit font-family from BODY.  CSS
specs says it should.  I don't see any ways to run around that bug, I just
want to know if somebody noticed that too, or if there is a doc on the web
that tells how Netscape and IE mess up CSS.

Neumann/Maus
François-Denis Gonthier
claudeg@icrdl.net
http://www.icrdl.net/claudeg        (The page I'm talking about isn't there)
Received on Thursday, 19 March 1998 02:30:45 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Monday, 27 April 2009 13:53:54 GMT