View Single Post

  #2 (permalink)  
Old 07-13-2003
Tom Thackrey
 
Posts: n/a
Default Re: How to use $GLOBALS


On 13-Jul-2003, reynoldscraigr@hotmail.com wrote:

> If I am understanding the documentation correctly, when you place info
> into $GLOBALS, it is avaialable anywhere, including on another page.
> Is this correct?


no it's only available on the page in which it was set.

>
> The reason I ask is that I am putting the value of a variable into
> $GLOBALS, and I can get its value then and there, but when I go to
> another page, the value that I put into $GLOBALS no longer seems to be
> in existence.


saving variables between pages is often done with sessions:
http://www.php.net/manual/en/ref.session.php


--
Tom Thackrey
www.creative-light.com
Reply With Quote