Help! Unexpected session behaviour - constantly reloading - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20) +--- Forum: Archived Development & Programming (https://forum.codeigniter.com/forumdisplay.php?fid=23) +--- Thread: Help! Unexpected session behaviour - constantly reloading (/showthread.php?tid=52087) |
Help! Unexpected session behaviour - constantly reloading - El Forum - 05-29-2012 [eluser]Unknown[/eluser] Hi, I'm having trouble using the session library. For some reason, my sessions simply do not last, and are reloaded with the page. I'm monitoring the session_id after login, and every time I refresh the page it changes, rather than staying the same. Subsequently any information I stored in the session is gone, and the session is useless. I managed to find a thread created in 2010 where this problem was prominent, however I wasn't able to resolve the issue and I can no longer find the thread. I did however read that the issue was with using localhost, so I am now using 127.0.0.1 (apparently a period or two is required in the domain). I do not have the database enabled for these sessions. Can anyone help? config: http://pastie.org/3989153 Sample code: Code: $this->session->set_userdata('test1', $test1); Help! Unexpected session behaviour - constantly reloading - El Forum - 05-29-2012 [eluser]Unknown[/eluser] Got a working test case together, and manage to locate where my problem was in production. Problem solved, this thread may be locked. Help! Unexpected session behaviour - constantly reloading - El Forum - 05-29-2012 [eluser]weboap[/eluser] http://ellislab.com/codeigniter/user-guide/libraries/sessions.html Quote: Help! Unexpected session behaviour - constantly reloading - El Forum - 05-29-2012 [eluser]Aken[/eluser] weboap, you should use [ quote ] instead of [ code ] for stuff like that. aaronds, you should post what the problem and solution was in the future, in case someone else has a similar situation and is searching for an answer. |