Welcome Guest, Not a member yet? Register   Sign In
empty session path
#1

Hi, I've looked a while here, googled but found no hint.

My site https://www.MYDOMAIN uses sessions without problem, the session path is empty, however.
For testing i use version.MYDOMAIN and sessions are lost. here the session path is empty as well.

sess_cache folder has '777'

My config file is

$config['sess_driver'] = 'files';
$config['sess_cookie_name'] = 'ci_session';
$config['sess_expiration'] = 7200;
$config['sess_save_path'] = FCPATH . 'sess_cache';


$config['sess_match_ip'] = FALSE;
$config['sess_time_to_update'] = 300;
$config['sess_regenerate_destroy'] = FALSE;

$config['cookie_prefix'] = '';
$config['cookie_domain'] = '';
$config['cookie_path'] = '/';
$config['cookie_secure'] = FALSE;
$config['cookie_httponly'] = FALSE;

What might be wrong with my setup?
Reply
#2

(This post was last modified: 01-29-2018, 08:49 AM by dave friend.)

I haven't had enough coffee today so I'm not sure what you mean by "the session path is empty,"

Does that mean that $config['sess_save_path'] = ''; or that FCPATH/sess_cache/ has no files in it?

Either way try
PHP Code:
$config['cookie_domain'] = '.MYDOMAIN'
Reply
#3

thanks dave, my question was unclear. sure.
there are no files in the directory FCPATH/sess_cache/ , but PHPSESSID are mentioned in the Application storage of the developer tools.
therefore, I assume that native php sessions are being used.
latest CI, php 7
Reply
#4

Hi dave, my question was unclear. the folder FCPATH . 'sess_cache'; is empty, changing the $config['cookie_domain'] didn't help, thank you anyway.

in the application storage of the developer tool, PHPSESSIONS are being shown. so I think, that native php sessions are used.

I did not change anything so I'm very confused what I might do wrong.
Latest CI 3.1.4, php 7
Reply
#5

CI 3.1.4 is not "latest", it's 3 releases behind.

But your issue might be the session.auto_start INI setting.
Reply
#6

You're right: 3.1.7 is my version.
anyway, I've modified the $config['sess_cookie_name'] = 'sess';
More specific, without the underscore as before "ci_session"

and my "sess_save_path" starts to fill with data.

thank you guys, if that was coincidence or causality: ?

both servers "https://www.MYDOMAIN" and "version.MYDOMAIN" are working - at least they seem to as I've got data in the session folder and sessions work fine.

cheers and a big thanks
Reply




Theme © iAndrew 2016 - Forum software by © MyBB