Did you try the escapeshellcmd () function ?  - Russ

---
Toolshed Computer Productions - Professional PHP Hosting
     Hosting - Dedicated Servers - Design - Programming
     http://www.toolshed51.com

-----Original Message-----
From: Jeffrey Barendse [mailto:[EMAIL PROTECTED]]
Sent: Thursday, June 28, 2001 8:01 AM
To: [EMAIL PROTECTED]
Subject: [PHP] PHP & ImageMagick


In PHP I try to run a shell command with the following source code:

$fotonaam = 'convert -font arial -pointsize 20 -gravity center -fill
white -draw "text 5,5 VERKOCHT" image.jpg image2.jpg';
exec($fotonaam);

PHP runs the program but the -draw "text 5,5 VERKOCHT" is not executed
(there is no VERKOCHT in the image2.jpg). I tried everything but I can't
solve the problem. Could somebody explain to me how it's possible that the
program (convert) runs but there (seams to be) a problem with -draw "text
5,5 VERKOCHT". If I run the same command troughs telnet/ssh as root or
nobody it works fine

Is it something with the " and the combinative with the exec function (I
also tried \")?

Or is it because I run PHP in safe mode and the convert program tries to run
a external program what is not in the . path (you now, the basic safe mode
restriction)?

Please help me.. I'm getting despaired on this in. ;-)

Regards,

Jeffrey Barendse




-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]

Reply via email to