Re: [PHP] Q on php://stdin -- an answer!

2002-02-21 Thread Billy S Halsey
on Solaris 8. Thanks in advance, -bsh Billy S Halsey wrote: Hi all, I've been trying for the last three hours to do something like this: #!/usr/local/bin/php -q ?php $fp = fopen(php://stdin, r); while (!feof($fp)) { $line = fgets($fp, 4096

Re: [PHP] Q on php://stdin

2002-02-20 Thread Billy S Halsey
Hi all, I still have been completely unable to get this to work like it should. I have a simple script: #!/usr/local/bin/php -q ?php $fp = fopen(php://stdin, r); while (($buf = fgets($fp, 512)) != false) { $input .= $buf; } echo $input; ? So if I call this echo.php

[PHP] Q on php://stdin

2002-02-18 Thread Billy S Halsey
Hi all, I've been trying for the last three hours to do something like this: #!/usr/local/bin/php -q ?php $fp = fopen(php://stdin, r); while (!feof($fp)) { $line = fgets($fp, 4096); print $line; } fclose($fp