Help - Search - Members - Calendar
Full Version: A Real Brain Twister
HTMLHelp Forums > Web Authoring > Cascading Style Sheets
marwood
Hello,

I'm having a problem with one of my webpages. I'm using a large background image in the body of my html which has it's CSS background-position property set to "center top;". This works great, as the image continues to centre as you resize the window. The divs inside my page also center, so they seamlessly work with the background of the page as you are resizing the window...

Up until a point...

As soon as the div hits the left edge of the browser window (upon resizing with the bottom right handler of the browser) the div stops in it's tracks and the background image continues to move along. The two break out of sync and my beautiful look page is destroyed.

Is there a way round this?

There doesn't seem to be an emoticon that pleads for help...
Jack
pandy
Please post the URL to the page. smile.gif
Christian J
I suspect the DIVs have margins (or their parent elements have padding).

Apply the BG image to a centered DIV instead of to BODY.
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.
Invision Power Board © 2001-2010 Invision Power Services, Inc.