[thelist] php session variables problem
Brady Mitchell
mydarb at gmail.com
Sat Jul 12 12:51:39 CDT 2008
On Jul 12, 2008, at 742AM, Maganizo Monawe wrote:
> <?php
>
> session_start();
>
> session_register("stdate");
> session_register("etdate");
> session_register("ccode");
>
> ?>
You don't need the session_register function calls. Take another read
of the manual page, http://us.php.net/session_register, there is a
warning not to mix session_register and $_SESSION -- eliminating the
session_register calls should fix your problem.
Also note that if register_globals is turned off, this method does not
work properly. Since register_globals is off by default as of PHP 4.2,
and will not exist in PHP 6 -- I suggest that you start working
towards not relying on register_globals settings.
Brady
More information about the thelist
mailing list