Quote:
Originally Posted by pilotbob
What is the error? You should be able to pass a second parameter to the exec() function to get the results from the command line.
BOb
|
No error, nothing. Besides a 255 as return value - whatever that means.
Here, that is the test code:
<?
$toexe = "C:\\calibre\\html2lrf.exe -t test -a test -o C:\\documents\\155.lrf C:\\documents\\155.htm";
$output = array();
exec($toexe, &$output, &$num);
echo nl2br(print_r($output,true))."<br />".$num;?>
?>
And the output:
Array
(
)
255
$output is totally empty.
The funny thing: When I mispell the command name, let's say "html3lrf.exe" then I don't get any output either, but $num changes from 255 to 1.
Any ideas left? :-)