Re: STDOUT and STDERR with php.exe and php-win.exe on Win XP

From: Date: Mon, 20 Jun 2011 16:27:23 +0000
Subject: Re: STDOUT and STDERR with php.exe and php-win.exe on Win XP
References: 1  Groups: php.windows 
Request: Send a blank email to php-windows+get-30667@lists.php.net to get a copy of this message
On 20 June 2011 18:18, JDS <jds@forerunnertv.com> wrote: > I am trying to figure out how this all works on Win XP... > > When I call php.exe or php-win.exe from another script (AutoHotKey in my > case), do both of these programs use stdout and stderr? I know php.exe has a > console window and php-win.exe does not, but just need to know how they > output the results. > > Thanks STDOUT is the normal output for php.exe. To write to the STDERR, you can ... php -r "file_put_contents('php://STDERR', 'This is an error');" > PHP_STDOUT.txt 2> PHP_STDERR.txt 2011-06-20 17:26 16 PHP_STDERR.txt 2011-06-20 17:26 0 PHP_STDOUT.txt OOI. If you want to use PHP scripts to act as a filter. E.g. command | php script, then read http://docs.php.net/manual/en/install.windows.commandline.php -- Richard Quadling Twitter : EE : Zend : PHPDoc @RQuadling : e-e.com/M_248814.html : bit.ly/9O8vFY : bit.ly/lFnVea

« previous php.windows (#30667) next »