DEDECMS后台登录空白解决办法,dedecms
导读:dedecmsdedecms今天下载了一个新版的dedecmsv5.7安装之后突然发现登录后台发现空白了,我php环境是使用的php5.4系统,经过百度php5.4把@session_re织梦模板免费dede免费模板。
解决方法:
打开 /userlogin.class.php 文件,在当前文件搜索keepUser(),然后把这个下面的@session_register();给注释掉就行了!
当然要不影响,可以改成
修改完的函数:
function keepUser() { if($this->userID != '' && $this->userType != '') { global $admincachefile,$adminstyle; if(empty($adminstyle)) $adminstyle = 'dedecms';
if (!isset($_SESSION[$this->keepUserIDTag])) //@session_register($this->keepUserIDTag); $_SESSION[$this->keepUserIDTag] = $this->userID; if (!isset($_SESSION[$this->keepUserTypeTag])) //@session_register($this->keepUserTypeTag); $_SESSION[$this->keepUserTypeTag] = $this->userType; if (!isset($_SESSION[$this->keepUserChannelTag])) //@session_register($this->keepUserChannelTag); $_SESSION[$this->keepUserChannelTag] = $this->userChannel; if (!isset($_SESSION[$this->keepUserNameTag])) //@session_register($this->keepUserNameTag); $_SESSION[$this->keepUserNameTag] = $this->userName; if (!isset($_SESSION[$this->keepUserPurviewTag])) //@session_register($this->keepUserPurviewTag); $_SESSION[$this->keepUserPurviewTag] = $this->userPurview; if (!isset($_SESSION[$th织梦文章模板is->keepAdminStyleTag])) //@session_register($this->keepAdminStyleTag); $_SESSION[$this->keepAdminStyleTag] = $adminstyle; PutCookie('DedeUserID', $this->userID, 3600 * 24, '/'); PutCookie('DedeLoginTime', time(), 3600 * 24, '/'); $this->ReWriteAdminChannel(); return 1; } else { return -1; }
声明: 本文由我的SEOUC技术文章主页发布于:2023-07-19 ,文章DEDECMS后台登录空白解决办法,dedecms主要讲述解决办法,后台,CMS网站建设源码以及服务器配置搭建相关技术文章。转载请保留链接: https://www.seouc.com/article/web_31080.html