Bug #13512 Updated: The backtick operator only returns stdout, not stderr
| From: | edink@php.net | Date: | Fri, 05 Oct 2001 07:20:24 +0000 |
| Subject: | Bug #13512 Updated: The backtick operator only returns stdout, not stderr | ||
| References: | 1 | Groups: | php.dev |
| Request: | Send a blank email to php-dev+get-67320@lists.php.net to get a copy of this message | ||
ID: 13512
Updated by: edink
Reported By: strecket@hotmail.com
Old Status: Open
Status: Closed
Bug Type: Feature/Change Request
Operating System: FreeBSD
PHP Version: 4.0.5
New Comment:
What you want can be probably be achieved with:
$output =
command 2>&1;
Previous Comments:
------------------------------------------------------------------------
[2001-10-02 10:27:43] strecket@hotmail.com
If I use the backtick operator, like:
$output = command goes here;
and if the program 'command' returns its output to stderr and not stdout, then it's
not easy to get the output.
Right now, it can be solved by adding:
2> /tmp/file/here
and then reading the file in the script, but that's not a good solution.
------------------------------------------------------------------------
Edit this bug report at http://bugs.php.net/?id=13512&edit=1