CodeIgniter Forums
Problem: Session cookie regenerating on every refresh. - Printable Version

+- CodeIgniter Forums (https://forum.codeigniter.com)
+-- Forum: Using CodeIgniter (https://forum.codeigniter.com/forumdisplay.php?fid=5)
+--- Forum: General Help (https://forum.codeigniter.com/forumdisplay.php?fid=24)
+--- Thread: Problem: Session cookie regenerating on every refresh. (/showthread.php?tid=66223)



Problem: Session cookie regenerating on every refresh. - oink - 09-23-2016

Hi, 

This is my configuration:
Code:
$config['sess_driver'] = 'database';
$config['sess_cookie_name'] = 'ktprj_kotki_session';
$config['sess_expiration'] = 2592000;
$config['sess_save_path'] = 'ci_sessions';
$config['sess_match_ip'] = FALSE;
$config['sess_time_to_update'] = 300;
$config['sess_regenerate_destroy'] = FALSE;


$config['cookie_prefix']    = '';
$config['cookie_domain']    = ''; //Its subdomain dogs.google.com like. tried with it or without it..
$config['cookie_path']        = '/';
$config['cookie_secure']    = TRUE; //I use cloudflare free ssl tried both on off
$config['cookie_httponly']     = FALSE;


I tried many variants, and on every page refresh value of sess_cookie_name is changing and new entry in ci_session table appears.



RE: Problem: Session cookie regenerating on every refresh. - oink - 09-23-2016

Problem solved!

I switched to PHP version 6.5 from 7.0.10/also tried 7.1.

...


RE: Problem: Session cookie regenerating on every refresh. - oink - 09-24-2016

I wonder where the problem can be? PHP 7.0/7.1 are much faster than 5.6..?


RE: Problem: Session cookie regenerating on every refresh. - soyjonathanespinosa - 10-10-2016

Can you help me? I have a similar problem, if I enter https://www.mydomain.com the cookie dissapear and all the session variables are deleted, but this not happen without www. can you assist me?

I have php 7, Cpanel and Codeigniter last version.

Thank you