DedeCMS后台,页面无显示 ,后台页面空白
程序员文章站
2022-05-01 12:57:17
...
[php] view plaincopy
- ...
- $cuserLogin = new userLogin($admindir);
- if(!empty($userid) && !empty($pwd))
- {
- $res = $cuserLogin->checkUser($userid,$pwd);
- //success
- if($res==1)
- {
- $cuserLogin->keepUser();//此处以下无输出
- if(!empty($gotopage))
- {
- ShowMsg('成功登录,正在转向管理管理主页!',$gotopage);
- exit();
- }
- else
- {
- ShowMsg('成功登录,正在转向管理管理主页!',"index.php");
- exit();
- }
- echo "ok";
- }
- ...
[php] view plaincopy
- ...
- function keepUser()
- {
- if($this->userID != '' && $this->userType != '')
- {
- global $admincachefile,$adminstyle;
- if(empty($adminstyle)) $adminstyle = 'dedecms';
- @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, '/');
- $this->ReWriteAdminChannel();
- return 1;
- }
- else
- {
- return -1;
- }
- }
Call to undefined function session_register()
证实了问题来源于此。查手册的描述如下:
"版本:(PHP 4, PHP 5 "本函数已自 PHP 5.3.0 起废弃并将自 PHP 5.4.0 起移除。"
[php] view plaincopy
- ...
- //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;
- ...
以上就介绍了DedeCMS后台,页面无显示 ,后台页面空白,包括了方面的内容,希望对PHP教程有兴趣的朋友有所帮助。
上一篇: yii2 页面底部加载css和js的技巧
下一篇: memchache的问题。