Codeigniter 3 Session not working With PHP 7.1.4

亡梦爱人 提交于 2019-11-27 04:47:10

问题


I have an application built with Codeigniter 3 HMVC.The application was working fine on PHP 5.6 version, But after upgrading my PHP version to 7.1.4 I was not able to log in into my application. After a complete checkup I found that session is not setting at all.

I role back to PHP 5.6 and session was working fine again while switching to PHP 7.1.4 bring the "session not working" issue back.

I tried altering some config value like cookie prefix and cookie save name etc, nothing seems to fix it.

Can anyone please help.


回答1:


I found that the issue is with some earlier version of Codeigniter 3 and this is a bug already reported in their website.The underlying session bug has been fixed on:

  • 3.1.2
  • 3.1.3
  • 3.1.4

So in the latest version of Codeigniter 3 this issue doesn't happen.

Solutions:

If you are already in a faulty version codeigniter consider replacing system folder with latest version's one. Version 3.1.6 at the time writing this.



来源:https://stackoverflow.com/questions/43718961/codeigniter-3-session-not-working-with-php-7-1-4

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