Here is what I am trying to accomplish. I want to create a backend for my client to use that will allow the following:
1. Allow them upload a max of 5 photos
2. The first photo will resize as a thumbnail, medium size and large size files into different folders
3. The other photos will save as medium and large size files in their respective folders
4. The names of each photo will save into a database (I will need to only call the medium photo sometimes)
So far I can do the multiple file upload, resize, and save into their respective folders using arrays and the foreach loop.
The challenge I am running into is that I can't figure out how to save the file/location to a separate column in a database (ie. thumbnail, medium, large).
Any suggestions?
Upload file, save to database, retrieve file.
Moderator: General Moderators
Re: Upload file, save to database, retrieve file.
I would name the images appropriately, md_imagename.jpg and lg_imagename.jpg and th_imagename.jpg, and store "imagename.jpg" in the database column. Where you need the medium image, call 'md_' . $imageNameFromDb and when you need the large image, do 'lg_' . $imageNameFromDb and where you need the thumbnail, do 'th_' . $imageNameFromDb.
Set Search Time - A google chrome extension. When you search only results from the past year (or set time period) are displayed. Helps tremendously when using new technologies to avoid outdated results.