I have a basic imagemagick script that works fine on windows, but wheni run it on the linux server (shared / hostgator) the images get created but the shave command doesnt get applied. The code im using is here:
$exp=path/to/file.jpg
$size = getimagesize("$exp");
$diff=abs($crop_h-$size[1]);
$shave = round($diff/2,0,PHP_ROUND_HALF_DOWN);
exec("convert $exp -shave 0x".$shave." $exp ");
thats it. works on localhost/windows but not live/linux. The images get generated (indicating IM is working), but the sides do not get shaved.
Any ideas?