cakephp loses sessions when using safari and internet explorer

只愿长相守 提交于 2019-12-09 22:56:43

问题


I'm using ajax and sessions for a cakephp project but it looks like the session gets lost when I use either safari or IE. I've followed the solutions in Sessions in IE and cakephp 1.3 not working properly when saving via AJAX I've set my core.php files to the settings below.

  Configure::write('Session.checkAgent', false);
  Configure::write('Security.level', 'low');

I've already upgraded my cake version to 2.3.0 and I'm still having the same issues. Please help? Thank you.

Here are my pastebins

jscript http://pastebin.com/WDCaTkEH

php - http://pastebin.com/YL7qkLf0


回答1:


there seems to be something wrong with cake somewhere ... adding session_start(); as first line on webroot/index.php solved the issue for me.




回答2:


I am using version 2.9. I add session_start(); in webroot/index.php -- It solved my problem There is something wrong in Cakephp.



来源:https://stackoverflow.com/questions/15166015/cakephp-loses-sessions-when-using-safari-and-internet-explorer

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!