View Full Version : Firefox bug on image background centering?!

10-19-2007, 03:20 PM
There is no problem with Safari or Internet Explorer 7. No problem in Firefox unless you resized browser to less than 1024 width (say 800px wide).

Check the template at: http://irishdeaf.com/template2008.html and resize Firefox browser to smaller and then scroll to the right. You will see the background isn't centering to the website but to your browser window! Is that a bug?

Also I'm not sure why there is a space on left when there's no space on the right? :confused:


10-19-2007, 03:38 PM
It is supposedly the correct implementation.
Corrected by adding width:995px; margin:auto; to the body

10-19-2007, 03:48 PM
Ahh thanks, just fixed the spacing.

So how do I center the background image to the page, not to the browser window? (especially firefox!)

10-19-2007, 03:51 PM
By moving the background image to #wrap and adjusting child element positions accordingly.

10-19-2007, 04:20 PM
Ok, would it be better to create another wrap - the outer wrap for background? Existing wrap would become an inner wrap.


EDIT: Well, I did it and added top/bottom padding to outer wrap. It's all good!

Big thanks to you otherwise I wouldn't have done it myself!