session.cookie_domain problem
| From: | Dustin Machi | Date: | Fri, 21 Nov 2003 19:09:43 +0000 |
| Subject: | session.cookie_domain problem | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-170603@lists.php.net to get a copy of this message | ||
I have a small application that uses adodb and session for user
management. The sessions are managed through the use of
adodb-session-clob.inc.php. The code snippet below shows what I do
related to sessions (minuse some variable assignment). $cookie_domain
is set to '.whatever.com' However, when I try to assign a cookie domain
neither mozilla or ie will accept the cookie as I would expect they
should. Konqueror on the other hand does accept it just fine. If I
comment out that line, the cookie is properly established by all
browsers, but only for that one particular host instead of for the
domain. I have searched around for this for a few days in the mailing
lists and bug db, but haven't really found a solution. I did see a
message from one other person about this quite some time ago, but there
was never a response to that person's inquiry. Does anyone have any
idea what I am doing wrong, or is this a known issue
Thanks, Dustin
// Set session parameters and start session
ini_set("session.gc_maxlifetime", "172800");
ini_set( "session.entropy_file","/dev/random");
ini_set( "session.entropy_length","512");
ini_set( "session.name",$session_name);
ini_set( "session.cookie_domain", $cookie_domain);
session_start();