CSS Background Image question

Ok, I don’t know if this is possible but I figured I would ask.

Is it possible to only show a background img/parts of a background img depending on a user’s browser resolution? This background is NOT repeatable so I can’t use the repeat x trick. But here is a sample scenario of my problem.

I have a background img of approx 1280 x 1024. The actual content of the site is approximately 1024x768. So I want my minimum size to be 1024x768 so that if a user’s browser size is 1024x768 or larger there will be NO scroll bars showing, but if the user’s browser resolution is higher than that, I want to show parts of the background or whole background (if the browser size is that size or larger).

Right now when I put the background img in a body or div tag…the browser will think that the website is actually 1280x1024 even though the real content is only 1024x768 therefore, if a browser window is only 1024x768 it will show scroll bars

Any help would be greatly appreciated!!!

Wow…I can’t believe I wrote a post for that haha. I thought I tried that and was getting scrollbars…turned out it was from another element.

Thanks!

If you want a background image, put it in the background.

body {
  background: white url(some.png) no-repeat;
  }

cheers,

gary