class.upload.php is a powerful and mature PHP class to manage uploaded files, and manipulate images in many ways. The script is available under a GPL license.
I used class.uplad.php in my script. Everything is working perfectly. Butr after a while it is going to timeout. I am handling almost 10000 thumbnails.
And the server where i am running this code, is a shared server. Some important php.ini values are as follows : memory_limit = 128 MB , max_execution_time = 300, max_input_time = 600, max_file_uploads = 20.
I used class.uplad.php in my script. Everything is working perfectly. Butr after a while it is going to timeout. I am handling almost 10000 thumbnails.
And the server where i am running this code, is a shared server. Some important php.ini values are as follows :
memory_limit = 128 MB , max_execution_time = 300, max_input_time = 600, max_file_uploads = 20.
Here is my code below
$foo = new Upload($img_dir . ORIGINAL_IMAGE_PATH ."/". $prod['image_folder'] . $prod['products_image']); if ($foo->uploaded) { $foo->image_resize = true; $foo->image_y = SMALL_IMAGE_HEIGHT; $foo->image_x = SMALL_IMAGE_WIDTH; $foo->Process($dir_dest_small); $foo->image_resize = true; $foo->image_y = PRODUCT_IMAGE_HEIGHT; $foo->image_x = PRODUCT_IMAGE_WIDTH; $foo->Process($dir_dest_display); $foo->image_resize = true; $foo->image_y = LARGE_IMAGE_HEIGHT; $foo->image_x = LARGE_IMAGE_WIDTH; $foo->Process($dir_dest_large); $foo->image_resize = true; $foo->image_y = OPI_IMAGES_MINHEIGHT; $foo->image_x = OPI_IMAGES_MINWIDTH; $foo->Process($dir_dest_adminthumb); $foo->image_resize = true; $foo->image_y = SMALL_IMAGE_HEIGHT; $foo->image_x = SMALL_IMAGE_WIDTH; $foo->Process($dir_dest_adminpreview); unset($foo); }Is anything wrong in my code ? Please suggest.
Thank you in advance.