I have a single image covering the entire background. Do sites that do this usually choose an image size via JavaScript? And if I didn’t want to use JavaScript, what’s a good minimum size to cover the vast majority of screens? Thanks.
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
There’s no way to tell, an image that would fit nicely on a 10″ netbook will not look the same on a 24″ monitor, so your best bet is to use a jQuery plugin such as the Backstretch or Vegas plugins or CSS3’s
background-size:coverproperty like so:Granted, that will only work on modern browsers. Here are a few more techniques to achieve this goal.