[thelist] JavaScript for body wrapper to be 100% height

jono at charlestonwebsolutions.com jono at charlestonwebsolutions.com
Mon Jan 8 15:21:17 CST 2007

> So, is there JavaScript that will tell the #wrapper to be 100% of the
> body's height, and fill the #wrapper <div> with a background color?

OK, so a colleague of mine came up with the following:

<script language="JavaScript">
    newCol = "#888888";
    document.bgColor = newCol;

This works great to make the bg color a solid color, but ideally I need to
still get a #wrapper to be 100% of the body's height so that I can apply a
bg color and possibly an image to the <div id="wrapper"> that will fill
out the entire page's body.

The problem in doing this is CSS way is that I am forced into Quirksmode
in IE, hence the JS.


More information about the thelist mailing list