OhLordy
07-16-2003, 03:12 AM
Hi, I'm trying to do a simple resize with ImageMagick's convert -resize this is my script
<?
$image_path="./img/";
$thumb_path="./thumb/";
$image_name="fpoi_highlow2.jpg";
$command="convert ".$image_path.$image_name." -resize 120x120 ".$thumb_path.$image_name;
echo($command);
$error=shell_exec($command);
echo($error);
?>
Now, if I cut and paste the echoed $command and run it from the command line it works fine. Also there is not error returned from shell_exec but for some reason the script is not working, there is no file in ./thumb after the completion of the script. Any ideas?
Cheers
Rob
<?
$image_path="./img/";
$thumb_path="./thumb/";
$image_name="fpoi_highlow2.jpg";
$command="convert ".$image_path.$image_name." -resize 120x120 ".$thumb_path.$image_name;
echo($command);
$error=shell_exec($command);
echo($error);
?>
Now, if I cut and paste the echoed $command and run it from the command line it works fine. Also there is not error returned from shell_exec but for some reason the script is not working, there is no file in ./thumb after the completion of the script. Any ideas?
Cheers
Rob