Re: Problem with session on first page loaded

From: Date: Fri, 02 Jul 2004 10:01:55 +0000
Subject: Re: Problem with session on first page loaded
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-189524@lists.php.net to get a copy of this message
Angelo, thanks for your comments. session_name must go before session_start. I think register_globals has nothing to do with session cookies. I always work with register_globals = off as recommended. About the cookie params (In PHP.INI) I checked them on the two platforms with phpinfo() and are exactly the same. I'm relly lost with this issue. It is not a browser problem, because browsers are accepting (and saving) the cookies. I tested it with Firefox, MSIE and Mozilla, and always have the same issue. Why the first page loaded, and only the first one, passes the session ID on the URL? I think perhaps could be something related with the system trying to read the cookie on the same page that first created it. But don't find a way to solve it. Thanks for your time, Jordi. Angelo binc2 wrote:
shouldn't session_start() come first? also remember that your devel computer might have different settings in the PHP.ini file to that of your ISP, probably register_globals is set to off. I would check it. HTH Angelo
Jordi Canals <llistes@jcanals.net> 7/2/2004 11:14:28 AM >>>
session_name('jcwse'); session_start();


« previous php.general (#189524) next »