in ,

How to Crop And Upload Image with PHP


Many times we need to crop the photo in the web application. This is simple PHP code which will crop 100px X 100 px photo. Change the code according to your need. You can also add some more effects to the code and integrate it with some big applications.

The code is not similar to the snapshot. This code will crop the image specified in $filename variable.

Crop image with PHP

Save Cropped image on server

Above code will show the cropped part of the image in the browser. If you want to save this cropped image. you should replace header code with the other line of code. See below:




Written by Deepanker

Deepanker Verma is the founder of Techlomedia. He is a tech blogger, developer and gadget freak.

Leave a Reply

Your email address will not be published. Required fields are marked *


Hover Image Zoom Effect With JQuery

7 Free PHP Captcha Scripts