Re: [PHP] Creating Session Variables

2003-04-03 Thread trlists
On 3 Apr 2003 CPT John W. Holmes wrote: No, $varname isn't created. You don't need it. You have a variable called $_SESSION['varname'], just use that where ever you need it (even within functions). If register_globals is on, you should be using the session_register() method, anyhow, not the

RE: [PHP] Creating Session Variables

2003-04-03 Thread John W. Holmes
No, $varname isn't created. You don't need it. You have a variable called $_SESSION['varname'], just use that where ever you need it (even within functions). If register_globals is on, you should be using the session_register() method, anyhow, not the one above. I have register_globals

Re: [PHP] Creating Session Variables

2003-04-03 Thread Jason Wong
On Friday 04 April 2003 03:47, Tom Rawson wrote: Hmmm, this doesn't seem clear in the docs ... Consider this: function foo() { $_SESSION['varname'] = test; . } At this point: - Can I reference $varname inside the function? If so, must it be

Re: [PHP] Creating Session Variables

2003-04-03 Thread CPT John W. Holmes
Consider this: function foo() { $_SESSION['varname'] = test; . } At this point: - Can I reference $varname inside the function? If so, must it be declared global first? Or can I only reference it via $_SESSION['varname']? - Can I reference it outside the function (as $varname)