Zuber Mafat Zuber Mafat - 4 months ago 13
PHP Question

How to share session between two CodeIgnitor applications in same domain

My Project Folder structure :

=>TestProject (Main Folder)
- applicationOne
- applicationTwo


how to use applicationOnesession to applicationTwo directory?

Answer

I am not sure, but you have to point session path to same directory in both sub applications in below code https://github.com/bcit-ci/CodeIgniter/blob/develop/application/config/config.php#L377

$config['sess_save_path'] = 'path_of_session_directory'

and make sure your cookie domain is same in both application