nsitedesigns
asked on
background image grows with monitor size
How do I create a site that has a background image that grows with monitor size but doesn't get distorted PLUS it stays put? I've done websites with backgrounds that don't move but never one that resizes.
Here is a perfect example.
http://www.travelwisconsin.com/
Here is a perfect example.
http://www.travelwisconsin.com/
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
won't that mean it will take a long time to load on slower connections?
Not if you optimize the image...if you keep the image file size down it will still load fast like the web url you provided.
Photoshop does a great job in letting you know which format is the best for optimization...generally jpg.
Photoshop does a great job in letting you know which format is the best for optimization...generally jpg.
ASKER
Is there a size that I should not exceed? What is the biggest I should shoot for?
I would say 2400 wide...there aren't too many that exceed that...for now...
Their background image is 315kb - I wouldn't say that is optimized!
Supersize! http://buildinternet.com/p roject/sup ersized/
One Perfect solution for you is:
http://css-tricks.com/perfect-full-page-background-image/
and get example:
http://css-tricks.com/examples/FullPageBackgroundImage/css-1.php#
http://css-tricks.com/perfect-full-page-background-image/
and get example:
http://css-tricks.com/examples/FullPageBackgroundImage/css-1.php#
ASKER
GaryC123,
Your option of Grow Media seems to be the most browser friendly.
http://growmedia.ca/blog/2009/10/14/resizable-full-browser-background-image-with-jquery-preserving-aspect-ratio/
The other options provided by other experts were interesting but some had browser limitations or were not optimized, or were a slideshow and I didn't need a slideshow.
I tried it but could not get my sample page to display image. I do not know js. Would you be willing to take a peek to see what I did wrong? If you can fix it, I will award you the points.
http://plymouthwisconsin.com/3.html
http://plymouthwisconsin.com/3.css
http://plymouthwisconsin.com/3.js
Your option of Grow Media seems to be the most browser friendly.
http://growmedia.ca/blog/2009/10/14/resizable-full-browser-background-image-with-jquery-preserving-aspect-ratio/
The other options provided by other experts were interesting but some had browser limitations or were not optimized, or were a slideshow and I didn't need a slideshow.
I tried it but could not get my sample page to display image. I do not know js. Would you be willing to take a peek to see what I did wrong? If you can fix it, I will award you the points.
http://plymouthwisconsin.com/3.html
http://plymouthwisconsin.com/3.css
http://plymouthwisconsin.com/3.js
ASKER
HOLD THE PHONE! One of the links that I failed to try earlier seems to work pretty good!
http://css-tricks.com/examples/FullPageBackgroundImage/css-1.php#
I am now testing it on browsers.
http://plymouthwisconsin.com/4.html
http://css-tricks.com/examples/FullPageBackgroundImage/css-1.php#
I am now testing it on browsers.
http://plymouthwisconsin.com/4.html
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Well, your js is failing because you have numbers before the code...
remove the 1,2,3,4,5 -- 39 before the code...then it might work.
remove the 1,2,3,4,5 -- 39 before the code...then it might work.
ASKER
Good catch. I removed the numbers but it still fails. Big fat white screen.
http://plymouthwisconsin.com/3.html
I tested 4.html and it doesn't test well. So I am back to troubleshooting 3.html
http://plymouthwisconsin.com/4.html
http://plymouthwisconsin.com/3.html
I tested 4.html and it doesn't test well. So I am back to troubleshooting 3.html
http://plymouthwisconsin.com/4.html
Can you post the image you are using too?
ASKER
here you go.
ASKER
lets try this again....
back-leaves-fall.jpg
back-leaves-fall.jpg
ASKER
weird, my file name is actually back_leaves_fall.jpg but after I uploaded it, it converted the underscores to dashes.
Ok, this is working for me...unzip and replace your other files...
package.zip
package.zip
ASKER
I tried clicking on the package.zip link and it opened new blank window. Tried dragging zip file to desktop and opening it but it was blank too. DId i do something wrong?
You have to save the zip file to a place on your computer...then unzip the zipped file to where you have the same files on your web server...
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Nukit,
I have another question open regarding this coding. Please take a peek and let me know if you can help me. The subject is "background image that grows positioning". Another opportunity for more points!
I have another question open regarding this coding. Please take a peek and let me know if you can help me. The subject is "background image that grows positioning". Another opportunity for more points!
Yeah, I think you closed this question, without handing out the points correctly. Instead of closing it you should select who's solution was the answer to your problem...then it will auto close it out...but now we get less points...oh well.
ASKER
I assigned a best answer (you) and then 2 supporting answers (you and Gary). Not sure why question didn't close out. I closed it like I normally do....
I opened a NEW question on this coding and thought you would be able to help me out.
I opened a NEW question on this coding and thought you would be able to help me out.
ASKER
thanks all!
The image size is: 2000px wide by 1200px high. It's positioned in the upper-left hand corner of the screen so it never moves...