How to access standard PHP session data from inside CodeIgniter?

Have you put session_start() in your index. Php?

Oh, geez... I'm used to doing that up-front when I build a project from scratch. Didn't think of doing that in CI. I just put a session_start() in the single controller function that I needed it, instead of putting it in CI globally.

– mogmismo Sep 20 '10 at 21:54.

This should work: if (!$this->session->userdata('user_id')){ $this->session->set_userdata('usermap', $_SESSION'user_id'); } You should use the session provided by CodeIgniter instead of mixing in native sessions.

I've got a Codeigniter project I'm working on, and using the CI Sessions (stored in a DB), but I need to check for a variable in another $_SESSION from another application (in the same cookie domain), but when I try, from the CI controller to use native PHP sessions to get this one bit of info ($_SESSION'blah'), it looks like CI is stripping out that global $_SESSION data. Anyone know a way I can get at it? Any help would be appreciated.

I cant really gove you an answer,but what I can give you is a way to a solution, that is you have to find the anglde that you relate to or peaks your interest. A good paper is one that people get drawn into because it reaches them ln some way.As for me WW11 to me, I think of the holocaust and the effect it had on the survivors, their families and those who stood by and did nothing until it was too late.

Related Questions