PHP Class: Image Resizing
Class supports source/destination images as jpeg, png, or gif automatically identifying the type from the filename, and allows for:
- Proportional resizing based on a provided width or height (but not both) resulting in e.g. a 200px wide image, and a height proportionally scaled to the original.
- Fixed proportional resizing with cropping based on a provided width and height resulting in an image that will first be scaled and then cropped from the centre to exactly match both provided dimensions.