Welcome Guest, Not a member yet? Register   Sign In
Multiple session entries
#1

[eluser]Unknown[/eluser]
I saw another post similar to this but didn't want to hijack their thread.

I seem to be having a problem with multiple sessions being created for a few users.
When they hit my site it stores a session for them in the database. In the process of
them logging in it will create several more sessions for them and one of them will have
there session info (username, user_id, etc) saved as user_data in ci_sessions table.

My authentication required pages check for valid user info in the sessions table, but for this
user it never matches and redirects them back to the login page. Im assuming it's picking up
a new session for them and nothing is set.

I had the user go to a separate website that tests cookie storage and it seemed to work fine for them.

Is there anything else that would cause this behavior besides failing to set the cookie on their end?
Could there be something wrong with my site setting cookies? Or maybe im just doing something wrong?

Code:
$config['sess_cookie_name']        = 'foosession';
$config['sess_expiration']             = 7200;
$config['sess_encrypt_cookie']    = TRUE;
$config['sess_use_database']       = TRUE;
$config['sess_table_name']          = 'ci_sessions';
$config['sess_match_ip']               = TRUE;
$config['sess_match_useragent'] = TRUE;
$config['sess_time_to_update']    = 300;

$config['cookie_prefix']        = "";
$config['cookie_domain']        = "foodomain.com";
$config['cookie_path']          = "/";
$config['global_xss_filtering'] = TRUE;

// also have
$autoload['libraries'] = array('session','database');
I tried with sess_match_ip and sess_match_useragent set to FALSE also.
And my cookie_domain does match my domain. I just changed the name to protect the innocent Smile

Thanks,
-Zee


Messages In This Thread
Multiple session entries - by El Forum - 01-11-2011, 12:35 PM
Multiple session entries - by El Forum - 01-11-2011, 01:26 PM
Multiple session entries - by El Forum - 01-11-2011, 01:40 PM
Multiple session entries - by El Forum - 01-11-2011, 01:54 PM
Multiple session entries - by El Forum - 01-11-2011, 02:00 PM



Theme © iAndrew 2016 - Forum software by © MyBB