Re: questions about $_SERVER

From: Date: Mon, 12 Mar 2012 16:04:59 +0000
Subject: Re: questions about $_SERVER
References: 1 2 3 4 5 6 7 8  Groups: php.general 
Request: Send a blank email to php-general+get-316993@lists.php.net to get a copy of this message
On Sun, Mar 11, 2012 at 14:16, Tedd Sperling <tedd.sperling@gmail.com> wrote: > > As to placing an additional requirement (i.e., being predefined) on the definition as to what > constitutes a SuperGlobal is outside my understanding. As such, I must defer to the PHP Manual, > namely: > > http://php.net/manual/en/language.variables.superglobals.php > > This document clearly states that $GLOBALS is a SuperGlobal -- what am I not understanding > here? You are understanding it correctly, the only thing that's missing is the population. The variables are defined (set), but not all are populated. $GLOBALS is a superglobal, you're right; globals set from userland scripts are not superglobals, but do wind up in the $GLOBALS array. Thus, all superglobals are globals, but not all globals are superglobals. -- </Daniel P. Brown> Network Infrastructure Manager http://www.php.net/

« previous php.general (#316993) next »