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'm trying to set the configuration of the class to have, after uploading, always an image of 1500 x 550px, but I can not .. Obviously, the original image must be larger Could someone help me? thanks
image_ratio_crop will resize the image so that your surface is covered, cutting out extra parts of the image. image_ratio_fill will resize the image so that it fits all in your surface, and will fill in the rest with a color (or transparency).Reply
I'm trying to set the configuration of the class to have, after uploading, always an image of 1500 x 550px, but I can not ..
Obviously, the original image must be larger
Could someone help me? thanks
The setting that is almost correct
In order to fill in precise dimensions, you need to use _image_ratio_crop_ (or _image_ratio_fill):
image_ratio_crop will resize the image so that your surface is covered, cutting out extra parts of the image. image_ratio_fill will resize the image so that it fits all in your surface, and will fill in the rest with a color (or transparency).