Images for the web
Jul. 27th, 2010 07:19 pmSomebody must know the answer to this... a quick google didn't turn up anything sensible.
I have an image which is rather large - a couple of thousand pixels square. Ideally, I want to pop it in the middle of a webpage.
Now, I could guess at a minimum monitor size, resize the image, and away we go. But I was thinking: surely there's something more clever I can do, whereby those with large monitors get a sizeable image, and those with tiny monitors do not.
Is there?
If not, are there any sensible guidelines on max image sizes, etc?
I have an image which is rather large - a couple of thousand pixels square. Ideally, I want to pop it in the middle of a webpage.
Now, I could guess at a minimum monitor size, resize the image, and away we go. But I was thinking: surely there's something more clever I can do, whereby those with large monitors get a sizeable image, and those with tiny monitors do not.
Is there?
If not, are there any sensible guidelines on max image sizes, etc?
no subject
Date: 2010-07-27 07:12 pm (UTC)This way though of course the tiny-windowed user will still be downloading the whole vast image, just rescaling it in the browser. I don't think there is any way of actually on-the-fly resampling the image to a smaller size, short of perhaps some fantastical piece of JavaScript technology.
no subject
Date: 2010-07-27 07:54 pm (UTC)Pretty sure this is what Smugmug do with my photos hosted there.
no subject
Date: 2010-08-02 01:04 pm (UTC)For example:
@media screen and (min-width: 400px) and (max-width: 700px) { ... }will get used when the width is between 400 and 700 pixels.
no subject
Date: 2010-08-02 02:35 pm (UTC)