PHP Methods to save image:
$targ_w = $targ_h = 150;
$jpeg_quality = 90;
$src = 'demo_files/pool.jpg';
$img_r = imagecreatefromjpeg($src);
$dst_r = ImageCreateTrueColor( $targ_w, $targ_h );
This will simply show image on crop if you want to save that image in some directory then make changes in last two line as below.
// minSize:[200,200], start minimum image size
// maxSize:[200,200], max size should be...