note 40856 added to function.shell-exec
| From: | dj-bj at gmx dot net | Date: | Wed, 17 Mar 2004 10:22:35 +0000 |
| Subject: | note 40856 added to function.shell-exec | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-66948@lists.php.net to get a copy of this message | ||
shell_exec passes the result to a variable only if the result of the command is true.
When the result is false the generated page contains the error string in clear text at the position
the result was fetched (which can differ from reload to reload).
If you would like to recieve also the error messages append 2>&1 to the end of the command
you are executing.
However, the result is also passed to the page directly.
To avoid page destruction you should not fetch the result in your script.
By appending >nul to the shell command you can hide any output.
Hope this helps.
----
Manual Page -- http://www.php.net/manual/en/function.shell-exec.php
Edit -- http://master.php.net/manage/user-notes.php?action=edit+40856
Delete -- http://master.php.net/manage/user-notes.php?action=delete+40856&report=yes
Reject -- http://master.php.net/manage/user-notes.php?action=reject+40856&report=yes
Search -- http://master.php.net/manage/user-notes.php