Re: getting $_ENV variables

From: Date: Wed, 09 May 2007 17:51:33 +0000
Subject: Re: getting $_ENV variables
References: 1 2  Groups: php.general 
Request: Send a blank email to php-general+get-254675@lists.php.net to get a copy of this message
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 and CGI and Apache module *are* different environments. Different things will be available to ENV when PHP runs. > I'm not certain about this, Cor, but my guess is that PHP 5.x.x > may have > altered the default $_ENV output to hide some of this information --- > which > is a good thing, in my opinion, because then you won't just have some > run-of-the-mill script kiddie checking out the details of a box for > known > security holes. Almost for sure, PHP just blindly passes on anything you are stupid enough to have crammed into ENV... :-) I doubt that it strips out anything, for any reason. -- Some people have a "gift" link here. Know what I want? I want you to buy a CD from some indie artist. http://cdbaby.com/browse/from/lynch Yeah, I get a buck. So?

« previous php.general (#254675) next »