Center oversized website background

Hi guys,

I’ve designed a website in Photoshop which I obviously want to convert to a real website. I’ve done this a lot of times before, so that isnt the problem. The problem is that the background of the website is very big (as in broad, big width). Its about 1400px big. Now the problem is that when you have a smaller resolution (1280 * 800 for instance) the image ‘starts’ in the left top… So the right part of the image isnt visible. Now my question is how to center a to big image so that the blocked part of the image is at the left as well as the right side…

I hope I made my problem clear…

body {
	background-image:url(untitled-1.jpg);

	background-position:center top;
}

^ That should do it! :slight_smile:

If your looking to scale the image to ‘fit’, you won’t be able to do this. However, if you just want it centered then you can go with this in your css:


background: url(path/to/image.gif) no-repeat top center;

  • ^ :stuck_out_tongue: beat me to it and you have your positions backwards…

Thanks guys! It works!