• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
how to turn off session

#1
[eluser]scieck[/eluser]
Does anybody knows a way to completely turn off cookies and sessions in CI ?

#2
[eluser]flaky[/eluser]
simply, don't load it

#3
[eluser]eoinmcg[/eluser]
by default codeigniter doesn't initiate sessions or send any cookies. so to answer your question you don't need to do anything - they are turned off.

#4
[eluser]scieck[/eluser]
thanks,
I inherited a project running on CI, I built a REST API on top of it, I don't have full knowledge of the code base yet. I can see from the HTTP headers that session cookies are passed in the responses and as I am not "loading it (session)" in the REST section I wrote it means the session is initiated somewhere else.
I'll look for it, thanks again.

#5
[eluser]eoinmcg[/eluser]
take a look in:
application/config/autload.php

if it's not there, check if the Controller class has been extended and loads it:
/application/libraries/MY_Controller.php

#6
[eluser]scieck[/eluser]
[quote author="eoinmcg" date="1271333614"]take a look in:
application/config/autload.php
[/quote]
Thank you, as you said, it was in fact in the
Code:
$autoload['libraries'] = {...}
array.


Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  


  Theme © 2014 iAndrew  
Powered By MyBB, © 2002-2021 MyBB Group.