Codeigniter session problem
i'm having trouble with Codeigniter sessions, every time that i refresh the system page, it creates another session, with another ID and keep duplicating the database session, every time that an new page it's loaded an new session it's created.
Thats my config array:
$config['sess_cookie_name'] = 'ssessions';
$config['sess_expiration'] = 7200;
$config['sess_expire_on_close'] = FALSE;
$config['sess_encrypt_cookie'] = FALSE;
$config['sess_use_database'] = TRUE;
$config['sess_table_name'] = 'ssessions';
$config['sess_match_ip'] = FALSE;
$config['sess_match_useragent'] = TRUE;
$config['sess_time_to_upda开发者_Python百科te'] = 300;
When the new session it's created, it has all old variables but have their values empty. Someone has an direction to solve it? (I'm using CI 2.0)
I don't know if dbsessions are part of your development requirements, but I've tried to used it and it seems no reliable. They love to fail.
In order to address the issue I've used the library Native Sessions and it seems working fine so far. You might find further information accessing http://codeigniter.com/forums/viewthread/103583/. It was design for CI 1.5 although you can find some tweaks to make it work on CI 2.0.
精彩评论