RE: [PHP] Command Line Arguments Don't Work

From: Date: Tue, 07 Nov 2000 02:16:17 +0000
Subject: RE: [PHP] Command Line Arguments Don't Work
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-24039@lists.php.net to get a copy of this message
To clarify here a bit: Reading the manual entry Jason links to might encourage you to try these options: echo $argv; echo $GLOBALS["argv"]; echo $HTTP_ENV_VARS["argv"]; echo $HTTP_ENV_VARS["argc"]; print_r($HTTP_ENV_VARS); You'll have no luck getting anything to print that resembles a command line option. The trick from John Donagher appears to be to use HTTP_SERVER_VARS. After coding in PHP for a few years now I'd never mastered this little trick, my unix background kept me thinking that command line variables were part of the enviroment. Whooops. No I know the truth. August > -----Original Message----- > From: Jason Brooke [mailto:jason@qgl.org] > Sent: Monday, November 06, 2000 6:02 PM > To: August Zajonc; Php-General > Subject: Re: [PHP] Command Line Arguments Don't Work > > > > This manual page contains the info you need: > http://www.php.net/manual/language.variables.predefined.php > > jason > > > > > Would someone be kind enough to describe how to access command line > > arguments? Please be sure to test what you do, I've seen far to many > > examples that don't work with php4.0.3pl1. Also check to see if you > have > > register_argv etc on or off. > > > > August > > > >

Attachment: [application/x-pkcs7-signature] smime.p7s
« previous php.general (#24039) next »