function _open should return true to avoid this error. It can not be null or empty whatever we use either database or file. When we use database to store session data, we keep it blank or no Boolean return. that is the main reason for this error. class session_handler{
public function __construct()
{
session_set_save_handler(
array($this, "_open"),
array($this, "_close"),
array($this, "_read"),
array($this, "_write"),
array($this, "_destroy"),
array($this, "_gc")
);
}
public function _open($savePath, $sessionId)
{
return true;
}
public function _close() { }
public function _read($id) { }
public function _write($id, $data) { }
public function _destroy($id) { }
public function _gc($max) { }}It is only for PHP 7. I do not know it is a bug or not. https://stackoverflow.com/questions/34125849/php-7-user-sessions-issue-failed-to-initialize-storage-module |
PHP 7 user sessions issue - Failed to initialize storage module
-
laravel Eloquent 如何实现 FIND_IN_SET ,并实现分页
有个文章表里面有个type字段,他存储的是文章类型,有 1头条,2推荐,3热点,4图文 .....11,12,13等等 现在有篇文章他既是 头条,又是热点,还是图文,
-
MySQL关于根据日期查询数据的sql语句
MySQL关于根据日期查询数据的sql语句
-
Failed to read artifact descriptor for org.apache.axis:axis:jar:1.4
pom这个报错,不一定是真的报错,看看下面的详解吧
-
cannot cast 'javax.xml.rpc.Call' to 'org.apache.axis.client.Call
用java调用axis报错的解决方案
-
jquery animate 连续点击不能平滑滚动的原因
通过设置延迟的方式解决平滑滚动
-
E45: 'readonly' option is set (add ! to override)
E45: 'readonly' option is set (add ! to override)
-
nginx 安装提示缺少pcre
经查看我的服务器里面有pcre,为什么还提示我缺少pcre。
-
启动Tomcat6.x时,manager does not exist or is not a readable directory-解决
几天重新安装了Tomcat6,安装完Tomcat6后在wepapps下面会有一些tomcat自带的项目(root、manager、host-manager等几个),这几天项目没什么用我就删掉了,后来在MyEclipse中配置好Tomcat,新建web项目,在启动Tomcat是会出现
-
Unable to set localhost. This prevents creation of a GUID
今天部署服务器,莫名其妙的出现了这样的问题,以前从没这情况过。
-
七牛上传图片 open failed: EACCES (Permission denied)
好久不做安卓了,把原来工程的七牛上传图片的代码粘贴过来,运行竟然出错了