JonnoTheDev Posted January 9, 2013 Share Posted January 9, 2013 I was asked a question recently which I couldn't give a definitive yes or no answer, so I have decided to throw it out there. Lets say we have a website where the admin or users or both can upload images into various sections i.e a photo galleries. When an upload is performed, the code will rename the file, crop the image to the required sizes, add watermarks, copy to various folders, and save the file name to the database, etc. All is good, however a few years down the line, the website owner wants a revamp and the new design uses different size images to the current design. So, the question is, when an image upload is performed, is it a good idea to store and keep the original image in case of a re-design. In this case a script can be written to generate new images from the original as opposed to the admin having to re-upload new images. The obvious issue is disk space as original images taken from digital cameras can be a few mb in size. Quote Link to comment Share on other sites More sharing options...
Philip Posted January 9, 2013 Share Posted January 9, 2013 Yeah, I'd store the original. Possibly shrink it down some (you likely won't need 5000x3000 px picture, even if cropping.) Diskspace is cheap these days Quote Link to comment Share on other sites More sharing options...
JonnoTheDev Posted January 9, 2013 Author Share Posted January 9, 2013 (edited) I was thinking maybe using the dropbox API to put the original image into an account and then remove it from the web server. If a script needed the original image it could use the API to fetch it from dropbox. Edited January 9, 2013 by neil.johnson Quote Link to comment Share on other sites More sharing options...
kicken Posted January 9, 2013 Share Posted January 9, 2013 For something like a photo gallery viewing the original image is one of the options people have. I code my gallery to show a grid of thumbnails, clicking a thumbnail opens a medium version (eg, 800x600) and clicking that will open the original image. For such a thing you'd have to store the original image anyway as part of the functionality of the script. If for some reason it is something that doesn't need the original as part of it's use, I'd still store it anyway probably. That way you can re-generate the thumbnail if need be. As mentioned, you could reduce the image some if it's gigantic, like maybe only store a max of 1280x1024 or similar. Quote Link to comment Share on other sites More sharing options...
JonnoTheDev Posted January 9, 2013 Author Share Posted January 9, 2013 I will have to look at keeping a copy of the original upload at a specific resolution as you guys have suggested for future projects. As I am not a designer I have never been given a design that required an original size image. I have always scaled and optimized images to the size required on the design and destroyed the original. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.