Re: system() Question
| From: | Nathan Nobbe | Date: | Sun, 28 Dec 2008 22:21:52 +0000 |
| Subject: | Re: system() Question | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-285163@lists.php.net to get a copy of this message | ||
On Sun, Dec 28, 2008 at 12:40 PM, Ryan O'Sullivan <rjo@rynet.com> wrote:
> Hello all,
>
> I am using system to convert some files using a binary in linux. My code
> looks like this:
> $response = system('gpsbabel -p "" -r -t -i gpx -f "test.gpx" -o
> kml -F
> "test2.kml"', $retval);
> echo "<p>Response: ", $response, "</p><p>Return Value:
> ", $retval;
>
> The $retval is returning code 127 - Any ideas on why this?<9¦PvÃ�äˆ
> èpT:œ�http://www.php.net/unsub.php>
you might try shell_exec() instead to see if you can get any more mileage.
the return value of shell_exec() is the output of the executed command.
-nathan