1

I am working on a Website and trying to decide if I should create separate thumbnail image for each image user uploads. Or just set a smaller width/height when displaying thumbnails.

I am planning to set a limit of image size to 2MB.

Any suggestion?

  • 3
    found this from W3Cschools: Tip: Downsizing a large image with the height and width attributes forces a user to download the large image (even if it looks small on the page). To avoid this, rescale the image with a program before using it on a page. I guess I've already known the answer - create separate thumbnial for each image uploaded. – sean717 Jun 23 '15 at 23:59
  • It's OK to answer your own question – Dan Pichelman Jun 24 '15 at 1:54
1

At least w3schools is right on this. It is indeed wiser to have a downsized image, or even several downsized images if you site needs it. Note that you may even want to have the "full size" image smaller than the user uploaded image.

You will have guessed that these images being user uploads, you'll need some kind of script to generate the thumbnails on the fly though. Finding an existing script to perform that shouldn't be an issue no matter which language you're using.

| improve this answer | |
1

found this from W3Cschools: Tip: Downsizing a large image with the height and width attributes forces a user to download the large image (even if it looks small on the page). To avoid this, rescale the image with a program before using it on a page. I guess I've already known the answer - create separate thumbnial for each image uploaded.

| improve this answer | |
1

You should create a thumbnail of the image uploaded by the user. It lessen the size of the page and makes it load faster.

| improve this answer | |

Not the answer you're looking for? Browse other questions tagged or ask your own question.