Click to See Complete Forum and Search --> : Body tag background image not displaying in FF


captsig
01-28-2009, 08:49 PM
Hi everyone,
Can someone explain why the following code works fine in IE(running Vista) but the background image in Mozilla FF displays only the bottom half
of the background image.

<style type="text/css">
body {
background-color:#FFFF99;
background-image: url(images/test_background2.gif);
background-repeat: no-repeat;
background-position: center center;
}

</style>
</head>

<body>

</body>
</html>

Thanks for your time.
Sig

goyney
01-29-2009, 01:01 AM
Try putting a min-height:###px on the body style where ### is the actual height of the background image.

Firefox is actually handling the CSS correctly. A background image shouldn't determine the height of a tag, the content that fills it should. Unfortunately, this is one of IE's bugs that people feel is done "correctly".

Let me know if providing that min-height works.

captsig
01-29-2009, 05:14 PM
Thanks very much. You nailed it. 'min-height:zzzzpx' fixed the problem.