You’re viewing an archive of outdated material. Visit The Web Standards Project’s updated site to learn about our current mission.

Box Model Properties on BODY

The following is the stylesheet for this document.

    HTML { margin: 32px; border: solid lime 16px;
           padding: 32px; background: green; color: white; }  

    BODY { margin: 32px; border: solid blue 16px;
           padding: 32px; background: navy; color: white; }  

This document should have a green margin of 32px, followed by a 16px lime border, followed by a 64px green area, a 16px blue border, a 32px navy padding, and this text should be white on navy.

Because MacIE treats the body and html elements in a special way, it fails to draw this page as described above. It puts 128px of space around the edges of the document, so it seems to be ignoring both borders and the background color on the html element.