RE: [PHP] backtick problem
| From: | Krznaric Michael | Date: | Fri, 11 Aug 2000 15:04:11 +0000 |
| Subject: | RE: [PHP] backtick problem | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-11339@lists.php.net to get a copy of this message | ||
If I remember correctly the backtick operator in perl sets the $? with the
error value(this is for perl, not php). Try examining that in your perl
script to see what the problem is? Wheter it's a path, environment issue or
wheter it even gets executed.
Mike
-----Original Message-----
From: Philip Fibiger [mailto:philip@colonize.com]
Sent: Friday, August 11, 2000 9:44 AM
To: php-general@lists.php.net
Subject: [PHP] backtick problem
Hi,
I've got a php script within which I call a perl program I wrote. I call
the program like this:
$output =
/home/bounce/testsend.pl;
print "<pre>$output</pre>";
now, testsend.pl uses backticks to call a few programs from the
commandline. when it runs from the php script, i see the output of the
perl program, but not the output from the stuff run in backticks (in perl)
and the programs in the perl backticks don't run (they're supposed to send
out email). If i su to the www user, and run testsend.pl, it runs
perfectly. I tried adding
putenv("HOME=/usr/home/");
putenv("USER=www");
to the php script before the backticks, but that didn't help.
Any help would be greatly appreciated.
Regards,
Philip
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- -
Philip Fibiger email:
philip@colonize.com
Programmer - Colonize.com phone:
607.256.1160x309
http://www.colonize.com "Unix is a set of tools
for smart
people"
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net
For additional commands, e-mail: php-general-help@lists.php.net
To contact the list administrators, e-mail: php-list-admin@lists.php.net