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.
Thanks for quick reply. Here is the log: system information - class version : 0.28 - GD version : 2.0 - supported image types : png jpg gif bmp - open_basedir : no restriction - language : en_GB source is an uploaded file - upload OK - file name OK determining MIME type - Checking MIME type with Fileinfo PECL extension Fileinfo PECL extension not available - Checking MIME type with UNIX file() command MIME returned as image/jpeg MIME type detected as image/jpeg by UNIX file() command source variables - You can use all these before calling process() file_src_name : t1larg.soda.fountain.cnn.jpg file_src_name_body : t1larg.soda.fountain.cnn file_src_name_ext : jpg file_src_pathname : /tmp/phpFkjDNA file_src_mime : image/jpeg file_src_size : 44574 (max= 2097152) file_src_error : 0 - source file is an image image_src_x : 640 image_src_y : 360 image_src_pixels : 230400 image_src_type : jpg image_src_bits : 8 process file to /home/redrain/www/gg/images/posts/012010/ - file size OK - file mime OK : image/jpeg - new file name body : gg_17f5c45fd3576fb5 - file name safe format - destination variables file_dst_path : /home/redrain/www/gg/images/posts/012010/ file_dst_name_body : gg_17f5c45fd3576fb5 file_dst_name_ext : jpg - no image operation, keep extension - checking for auto_rename - destination file details file_dst_name : gg_17f5c45fd3576fb5.jpg file_dst_pathname : /home/redrain/www/gg/images/posts/012010/gg_17f5c45fd3576fb5.jpg - gg_17f5c45fd3576fb5.jpg doesn't exist already - no image processing wanted - process OK Reply
I think that image_dst_x and image_dst_y are not populated because the image is not resized, or otherwise graphically manipulated (no image processing wanted).
In this case, image_dst_x and image_dst_y are equal to image_src_x and image_src_y. I will fix it for the next version.Reply
system information
- class version : 0.28
- GD version : 2.0
- supported image types : png jpg gif bmp
- open_basedir : no restriction
- language : en_GB
source is an uploaded file
- upload OK
- file name OK
determining MIME type
- Checking MIME type with Fileinfo PECL extension
Fileinfo PECL extension not available
- Checking MIME type with UNIX file() command
MIME returned as image/jpeg
MIME type detected as image/jpeg by UNIX file() command
source variables
- You can use all these before calling process()
file_src_name : t1larg.soda.fountain.cnn.jpg
file_src_name_body : t1larg.soda.fountain.cnn
file_src_name_ext : jpg
file_src_pathname : /tmp/phpFkjDNA
file_src_mime : image/jpeg
file_src_size : 44574 (max= 2097152)
file_src_error : 0
- source file is an image
image_src_x : 640
image_src_y : 360
image_src_pixels : 230400
image_src_type : jpg
image_src_bits : 8
process file to /home/redrain/www/gg/images/posts/012010/
- file size OK
- file mime OK : image/jpeg
- new file name body : gg_17f5c45fd3576fb5
- file name safe format
- destination variables
file_dst_path : /home/redrain/www/gg/images/posts/012010/
file_dst_name_body : gg_17f5c45fd3576fb5
file_dst_name_ext : jpg
- no image operation, keep extension
- checking for auto_rename
- destination file details
file_dst_name : gg_17f5c45fd3576fb5.jpg
file_dst_pathname : /home/redrain/www/gg/images/posts/012010/gg_17f5c45fd3576fb5.jpg
- gg_17f5c45fd3576fb5.jpg doesn't exist already
- no image processing wanted
- process OK
In this case, image_dst_x and image_dst_y are equal to image_src_x and image_src_y. I will fix it for the next version.
Thanks again.