views:

171

answers:

1

I found a very helpful post on here about cropping images in a circle. However, when I try to execute the imagemagick script using exec in PHP, I'm getting no results. I've checked to make sure the directories have the correct permissions and such. Is there a step I'm missing?

Any insight would be much appreciated. Here's what my script looks like:

$run = exec('convert -size 200x200 xc:none -fill daisy.jpg -draw "circle 100,100 100,1" uploads/new.png');

Edit: Imagemagick is installed.

+3  A: 
$out=array();
$err = 0;
$run = exec('convert -size 200x200 xc:none -fill daisy.jpg -draw "circle 100,100 100,1" uploads/new.png',$out,$err);
echo implode ("<br>",$out);
print_r($err);
print_r($run);

what would it say?

Col. Shrapnel
It says "127" which apparently means there is something wrong with the path.
Erik Smith
@erik just use absolute paths. both to the source and resulting picture
Col. Shrapnel