-->

您现在的位置: 首页 > 教程文档 > 织梦技巧 >

织梦dedecms5.7在php5.4环境下安装出现后台空白的原因

来源:未知 发布时间:2017-11-10热度:
好织梦小编经过查找资料发现,因为php5.4 已经不在使用ession_register函数这个函数 所以安装织梦的时候会出现后台空白 怎么处理? 解决方法:找开include/userlogin.class.php文件,查找以下内容: @session_register($this-keepUserIDTag); $_SESSION[$thi...

好织梦小编经过查找资料发现,因为php5.4 已经不在使用ession_register函数这个函数 所以安装织梦的时候会出现后台空白 怎么处理?
解决方法:找开include/userlogin.class.php文件,查找以下内容:

@session_register($this->keepUserIDTag);
$_SESSION[$this->keepUserIDTag] = $this->userID;
@session_register($this->keepUserTypeTag);
$_SESSION[$this->keepUserTypeTag] = $this->userType;
@session_register($this->keepUserChannelTag);
$_SESSION[$this->keepUserChannelTag] = $this->userChannel;
@session_register($this->keepUserNameTag);
$_SESSION[$this->keepUserNameTag] = $this->userName;
@session_register($this->keepUserPurviewTag);
$_SESSION[$this->keepUserPurviewTag] = $this->userPurview;
@session_register($this->keepAdminStyleTag);
$_SESSION[$this->keepAdminStyleTag] = $adminstyle;
PutCookie(‘DedeUserID’, $this->userID, 3600 * 24, ‘/’);
PutCookie(‘DedeLoginTime’, time(), 3600 * 24, ‘/’);

替换成

global $admincachefile,$adminstyle;
if(empty($adminstyle)) $adminstyle = ‘dedecms’;
//@session_register($this->keepUserIDTag);
$_SESSION[$this->keepUserIDTag] = $this->keepUserIDTag;
$_SESSION[$this->keepUserIDTag] = $this->userID;
//@session_register($this->keepUserTypeTag);
$_SESSION[$this->keepUserTypeTag] = $this->keepUserTypeTag;
$_SESSION[$this->keepUserTypeTag] = $this->userType;
// @session_register($this->keepUserChannelTag);
$_SESSION[$this->keepUserChannelTag] = $this->keepUserChannelTag;
$_SESSION[$this->keepUserChannelTag] = $this->userChannel;
//@session_register($this->keepUserNameTag);
$_SESSION[$this->keepUserNameTag] = $this->keepUserNameTag;
$_SESSION[$this->keepUserNameTag] = $this->userName;
//@session_register($this->keepUserPurviewTag);
$_SESSION[$this->keepUserPurviewTag] = $this->keepUserPurviewTag;
$_SESSION[$this->keepUserPurviewTag] = $this->userPurview;
// @session_register($this->keepAdminStyleTag);
$_SESSION[$this->keepAdminStyleTag] = $this->keepAdminStyleTag;
$_SESSION[$this->keepAdminStyleTag] = $adminstyle;
PutCookie(‘DedeUserID’, $this->userID, 3600 * 24, ‘/’);
PutCookie(‘DedeLoginTime’, time(), 3600 * 24, ‘/’);

责任编辑:好织梦

温馨提示

大家好,由于业务调整,本站的会员及支付购买等功能不能使用,本站织梦会员可以移步织梦58(http://www.dede58.com/)继续使用

其他建站朋友强烈推荐优秀的建站系统(易优CMS),建站简单、安全、易用,更有丰富的插件扩展!

如有其他问题可以联系客服(QQ:970003436)沟通,谢谢大家支持!!

关注易优CMS公众号,获取更多建站资讯