tedd wrote:
At 11:54 AM +0100 5/10/07, C.R.Vegelin wrote:
All I want is to check the $_ENV['OS'] within PHP scripts.
If all you want to do is to find out what the user's OS is, try this:
$_SERVER('HTTP_USER_AGENT')
Do print_r($_SERVER) to see all it contains.
He wanted to tell the OS of
At 11:54 AM +0100 5/10/07, C.R.Vegelin wrote:
All I want is to check the $_ENV['OS'] within PHP scripts.
If all you want to do is to find out what the user's OS is, try this:
$_SERVER('HTTP_USER_AGENT')
Do print_r($_SERVER) to see all it contains.
Cheers,
tedd
--
---
http://sperling.co
Okay, I will use getenv() and keep variables_order = GPCS in php.ini
Thanks all and
with regards, Cor
- Original Message -
From: "Richard Davey" <[EMAIL PROTECTED]>
To: "[EMAIL PROTECTED]"
Sent: Thursday, May 10, 2007 3:34 PM
Subject: Re: [PHP] getting $_EN
C.R.Vegelin wrote:
Yes, my PHPinfo shows under configuration: variables_order = GPCS
I will test EGPCS setting in php.ini
But that also means that code using $_ENV cannot be run with hosts
hiding the environment settings ?!
Correct. Sucks I know, but some hosts just do this.
And I assume
OTECTED]"
> Sent: Thursday, May 10, 2007 2:44 PM
> Subject: Re: [PHP] getting $_ENV variables
>
>
> > Daniel Brown wrote:
> >
> >>If it's suggesting that it's an array, that's a little baffling,
> >> because
> >> that mea
Daniel Brown wrote:
I guess I really didn't understand that myself before either. So
Richard, even though it's disabling data output, it still exists as an
array?
The array ($_ENV) exists, it is just the population of it that has been
disabled, thus it's empty. Just in the same way that d
: Array ( )
So also potential problems with $_FILES with hosts hiding the environment
settings ?!
Regards, Cor
- Original Message -
From: "Richard Davey" <[EMAIL PROTECTED]>
To: "[EMAIL PROTECTED]"
Sent: Thursday, May 10, 2007 2:44 PM
Subject: Re: [PHP] getting
I guess I really didn't understand that myself before either. So
Richard, even though it's disabling data output, it still exists as an
array?
Well, damn you really DO learn something new every day.
On 5/10/07, Richard Davey <[EMAIL PROTECTED]> wrote:
Daniel Brown wrote:
>If i
-
*From:* Daniel Brown <[EMAIL PROTECTED]>
*To:* C.R.Vegelin <[EMAIL PROTECTED]>
*Cc:* [EMAIL PROTECTED]
*Sent:* Thursday, May 10, 2007 2:24 PM
*Subject:* Re: [PHP] getting $_ENV variables
Cor,
If it's suggesting that it's an array, that's a little baffling,
becaus
Daniel Brown wrote:
If it's suggesting that it's an array, that's a little baffling, because
that means there are multiple entries (at least two), but they appear to
either be null or otherwise unable to display.
The $_ENV superb-global contains an array of environment settings, so
it's no
Subject: Re: [PHP] getting $_ENV variables
Cor,
If it's suggesting that it's an array, that's a little baffling, because
that means there are multiple entries (at least two), but they appear to either
be null or otherwise unable to display.
Did you get that resu
] within PHP scripts.
Regards, Cor
- Original Message -
*From:* Daniel Brown <[EMAIL PROTECTED]>
*To:* C.R.Vegelin <[EMAIL PROTECTED]>
*Cc:* [EMAIL PROTECTED]
*Sent:* Wednesday, May 09, 2007 5:26 PM
*Subject:* Re: [PHP] getting $_ENV variables
When I print_r($_ENV); from the CLI
--
From: Daniel Brown
To: C.R.Vegelin
Cc: [EMAIL PROTECTED]
Sent: Wednesday, May 09, 2007 5:26 PM
Subject: Re: [PHP] getting $_ENV variables
When I print_r($_ENV); from the CLI on 5.0.4 I get a bunch of results, no
problem but no $_ENV['OS'] variable. Further, when
On Wed, May 9, 2007 11:26 am, Daniel Brown wrote:
> When I print_r($_ENV); from the CLI on 5.0.4 I get a bunch of
> results,
> no problem but no $_ENV['OS'] variable. Further, when I check my
> phpinfo(); output, there are even fewer $_ENV variables printed than
> the CLI
> offers.
CLI an
On Wed, May 9, 2007 11:57 am, C.R.Vegelin wrote:
> I get nothing when using: echo $_ENV['OS'];
> Also nothing when using: print_r($_ENV);
> However, phpinfo(); show a full list of ENV settings.
> How to get $_ENV variables ?
> I am using PHP version 5.2.0.
If phpinfo() shows them, then that is wha
On 5/9/07, C.R.Vegelin <[EMAIL PROTECTED]> wrote:
I get nothing when using: echo $_ENV['OS'];
Also nothing when using: print_r($_ENV);
However, phpinfo(); show a full list of ENV settings.
How to get $_ENV variables ?
I am using PHP version 5.2.0.
You can get it other ways:
php -r 'system("se
When I print_r($_ENV); from the CLI on 5.0.4 I get a bunch of results,
no problem but no $_ENV['OS'] variable. Further, when I check my
phpinfo(); output, there are even fewer $_ENV variables printed than the CLI
offers.
I'm not certain about this, Cor, but my guess is that PHP 5.x.x m
17 matches
Mail list logo