James_Bhatta's avatar

What is a good image resizing and storing strategy?

A couple of questions.

Do you keep the original file uploaded by users in your applications after you resize them ?

Do you resize the image to a specific dimension in both axis or just adjust the height or weight and keep the aspect ratio?

Is it good approach to save the image path for different size images in a string columns ad json data instead of multiple fields?

Please let me know how do you usually maintain multiple size of images in your application. Thanks for your valuable time.

0 likes
2 replies
Tray2's avatar
Tray2
Best Answer
Level 73
  1. It depends, If the users should have access to the original image or not.
  2. One axis with aspec ratio otherwise you will get wonky images.
  3. I would say no. I much prefer to save them in different directories with the same filename. I also despise using json in my tables.
1 like

Please or to participate in this conversation.