Go Back   Graphic Design Forum > Graphic Design > Web Design

Web Design Web Design type posts here

Reply
 
Thread Tools Search this Thread Display Modes
Old 11-19-2009, 04:35 PM   #1
joshdesigns
Junior Member
 
Join Date: Nov 2009
Posts: 2
Background image for website- issue with different browser sizes

Hi all,

I have been trying to position a background image for a web page that suits the major browser sizes for my web template.
800X600px
1024x768px
1280x1024px
1600x1200px


(I am familiar with html,css,js to an extent but still learning.) I am wondering how to position the background image using css that will suit all the browser sizes.
The template i have is somewhat similiar to this : http://www.slicejack.com/
i need the background image to fit 100% of the screen size. I am having trouble trying to fit the image for all the browsers.I would appreciate any help.Thanks.

-josh
joshdesigns is offline   Reply With Quote
Old 11-19-2009, 07:48 PM   #2
vanishdesign
Web usability geek
 
vanishdesign's Avatar
 
Join Date: Feb 2009
Posts: 467
For that site's example:
You do a wrapper div that's <1000px wide, 920px, 960px, whatever. Make the important part of the background there, and have it fade into a generic color, gradient or pattern.

Then set the body tag's background image to the generic color/pattern.

Want to test how this will look on screens wider than yours? Use the zoom out feature in Firefox.
__________________
Swedish Meatball Pornography
vanishdesign is offline   Reply With Quote
Old 11-19-2009, 08:57 PM   #3
joshdesigns
Junior Member
 
Join Date: Nov 2009
Posts: 2
Thank you vanishdesign for your reply.I get the idea.(the idea with the div is great)
One concern i have is when i create the background image for the body( i usually do in PhotoShop) do i have to set the width,height to a certain parameter to suit all browsers or it doesnt matter since it is going to be a generic pattern.

What if background image of the body was not a generic pattern do you set the width and height to a particular parameter.? Thanks.
joshdesigns is offline   Reply With Quote
Old 11-19-2009, 09:55 PM   #4
Amonza
Junior Member
 
Join Date: Nov 2009
Posts: 14
body { background: #/*yourcolor*/ url('/*yourimage*/') top center no-repeat;}
Amonza is offline   Reply With Quote
Old 11-20-2009, 03:51 PM   #5
vanishdesign
Web usability geek
 
vanishdesign's Avatar
 
Join Date: Feb 2009
Posts: 467
You said you wanted it to look good on 800x600 screens, so I'd start with that. Generally, you should leave about 30, 40 pixels for the scrollbars/windowframe, so the actual maximized browser viewport should be about 770px wide. So you'd want to fit all the important part of the graphic within that width.

Another thing you could do, which slicejack seems to have done, is just make an incredibly wide image, like say 3000px wide, and set background-position: center in CSS. Obviously you will still have to limit the relevant part of the image to a fixed width, and if someone has some massive resolution, they may see it cut off.
__________________
Swedish Meatball Pornography
vanishdesign is offline   Reply With Quote
Reply

Bookmarks


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 02:19 AM.




GRAPHICS.COM NEWSLETTER
The weekly Graphics.com newsletter is a great way to stay up to date on what's new on the site and in the world of graphics. Subscribe »
JOB LISTINGS
Featured Listings
Agency Photo Producer
clm
New York, NY
Account Director/Strategist
Office
San Francisco, CA
Graphic Designer
Marketing Communications Organization
Newtown Square, PA
Studio Manager
Office: Jason Schulte Design, Inc.
San Francisco, CA

See all other great design jobs on our Job Board

Post a risk-free
job listing for $279


Latest Blog Entries

Let's Talk Generic
Mike Lenhart

Art in the House
Mike Lenhart

It's All Black and White To Me
Mike Lenhart

A Bite From The Apple
Mike Lenhart

The Outside In Approach to Social Networking
Chris Dickman

Don't Bite Your Nails!
Mike Lenhart



WebMediaBrands
mediabistro learnnetwork freelanceconnect SemanticWeb
Jobs | Events | News
Copyright 2010 WebMediaBrands Inc. All rights reserved.
Advertise | Terms of Use | Privacy Policy

Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2010, Jelsoft Enterprises Ltd.