Im alright with PHP but I'm struggling a bit to get this to work. So I have a directory called images. I have a cron job that adds images to this folder. I also need a job to go through and create thumbnails of all of the images that havent not yet been created or just add it to the end of my job that adds the images. Any advise on what thumbnail script to use and how to set it up?
just write a php program and add that to cron in php program get all the list of files one by one generate the thumbnail of required size save it in a different folder Thats all Regards Alex
I just waded through a 463 script list over at hotscripts. I know that I say one or more that would do this. Not sure about the cron part. Look in >php>scripts>image gallerys. If you want a really cool script to do this on your local windows machine, I highly reccommend pixresizer. I can locate the link for that one if Google fails you.
$image_dir = 'images/'; $thumb_dir = 'images/thumbs/'; $image_list = glob("$image_dir/*") foreach($image_list as $image){ $name = basename($image); if(!is_file($thumb_dir.$name)){ makeThumb($image_dir,$thumb_dir,$name); } } PHP: Use any function for the thumbnail for makeThumb. Peace,
Ended up figuring out how to immediately take the single image that was saved and then create a thumbnail of it - this then saves it back over the original image so I dont have to store the big one. Every time the script runs, it checks for that image and if it exists it goes onto the next one. Now I just need to find a different thumbnail script that I like a little more than the one I currently have. I'll take a look at the ones you guys posted. Thanks for your help.