Ahh ok, yeah, $_SERVER['argv'][1] works like a charm, thanks.
> Use $argv, that failing it definately works with $_SERVER['argv']
-Dan Joseph
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
> I have a php script that I want to run from a command line:
>
> % /usr/local/bin/php script.php 47264
>
> 47264 is the argument, however, I can't figure out how to access it inside
> the script. I thought it was the $ARG array or $ARGV, but I am mistaken...
> can only refresh me? searching di
Use $argv, that failing it definately works with $_SERVER['argv']
Cheers,
Rob.
On Wed, 2003-10-22 at 13:59, Dan Joseph wrote:
> Hi,
>
> I'm having trouble remember something
>
> I have a php script that I want to run from a command line:
>
> % /usr/local/bin/php script.ph
Hi,
I'm having trouble remember something
I have a php script that I want to run from a command line:
% /usr/local/bin/php script.php 47264
47264 is the argument, however, I can't figure out how to access it inside
the script. I thought it was the $ARG array
4 matches
Mail list logo