Re: cli version and shell useability
| From: | (Marcus Börger) | Date: | Tue, 05 Mar 2002 16:36:14 +0000 |
| Subject: | Re: cli version and shell useability | ||
| References: | 1 | Groups: | php.dev |
| Request: | Send a blank email to php-dev+get-80750@lists.php.net to get a copy of this message | ||
In addition to Markus Fischer: Does the CLI version has the ability
to execute code without <? and ?>.
Assuming "-s --" as solution. -s to skip <? and -- instead of -p from
Markus Fisher (other cmd utils like awk use -- too). This would allow:
php -s -- 'echo "hello world";'
From my point of view both are necessary to make php a widely
accepted shell script language. Also i would appreciate --help to
show up with version and supported switches.
marcus
to make
At 09:39 05.03.2002, Markus Fischer wrote:
Is there a way to execute code from the command line AND process stdin/stdout without using an external file with php code?Currently the only way of feeding code to the script (to my knowledge) is:echo '<? // code ....?>' | php >outputor<input stream> | php -f code.php >outputBut you can't do something like<input stream > | php -p '<? execute php code ?>' >outputMaybe I missed the last option?- Markus-- Please always Cc to me when replying to me on the lists. GnuPG Key: http://guru.josefine.at/~mfischer/C2272BD0.asc -- PHP Development Mailing List <http://www.php.net/> To unsubscribe, visit: http://www.php.net/unsub.php