search
HomeCMS TutorialDEDECMSWhat should I do if the background login interface is blank after installing dedecms?

What should I do if the background login interface is blank after installing dedecms?

Foreword:

(Learning video sharing: Introduction to Programming)

php version: 5.4.4

What should I do if the background login interface is blank after installing dedecms?

Everything went smoothly during the installation. When logging in to the backend, a blank page was displayed after filling in the username and password. Solution:

Find include/userlogin.class .php, which contains a keepuser() function, which uses session_register to register a session variable. However, this function has been removed in php5.4. See the official website introduction:

What should I do if the background login interface is blank after installing dedecms?

If you use this php version, there will definitely be an error, but we can modify the code:

Comment out @session_register($this->keepUserIDTag); and then change it to
if ( !isset($_SESSION[$this->keepUserIDTag]))

There are six in total, all changed to the following:

1 if (!isset($_SESSION[$this->keepUserIDTag]))
 2 //@session_register($this->keepUserIDTag);    
 3 $_SESSION[$this->keepUserIDTag] = $this->userID;
 4 
 5 if (!isset($_SESSION[$this->keepUserTypeTag]))
 6 //@session_register($this->keepUserTypeTag);
 7 $_SESSION[$this->keepUserTypeTag] = $this->userType;
 8 
 9 if (!isset($_SESSION[$this->keepUserChannelTag]))
10 //@session_register($this->keepUserChannelTag);
11 $_SESSION[$this->keepUserChannelTag] = $this->userChannel;
12 
13 if (!isset($_SESSION[$this->keepUserNameTag]))
14 //@session_register($this->keepUserNameTag);
15 $_SESSION[$this->keepUserNameTag] = $this->userName;
16 
17 if (!isset($_SESSION[$this->keepUserPurviewTag]))
18 //@session_register($this->keepUserPurviewTag);
19 $_SESSION[$this->keepUserPurviewTag] = $this->userPurview;
20 
21 if (!isset($_SESSION[$this->keepAdminStyleTag]))
22 //@session_register($this->keepAdminStyleTag);
23 $_SESSION[$this->keepAdminStyleTag] = $adminstyle;

Re-enter the background and log in, you can jump to the normal Manage the page.

PS: I have been struggling with this problem of blank login background for a long time, but I still can’t find a solution because I am not familiar with PHP. It is generally said on the Internet that it is a problem with the encoding of the data/common.inc.php file. , the encoding needs to be changed to a BOM-free format file to save, but it is not said to be a problem with php5.4. The most important thing is that the official website of DreamWeaver has not explained it, and some people have asked this question on the official website forum but there is no answer. It is frustrating. ! But now it's finally solved.

Related recommendations: dedecms tutorial

The above is the detailed content of What should I do if the background login interface is blank after installing dedecms?. For more information, please follow other related articles on the PHP Chinese website!

Statement
This article is reproduced at:博客园. If there is any infringement, please contact admin@php.cn delete

Hot AI Tools

Undresser.AI Undress

Undresser.AI Undress

AI-powered app for creating realistic nude photos

AI Clothes Remover

AI Clothes Remover

Online AI tool for removing clothes from photos.

Undress AI Tool

Undress AI Tool

Undress images for free

Clothoff.io

Clothoff.io

AI clothes remover

Video Face Swap

Video Face Swap

Swap faces in any video effortlessly with our completely free AI face swap tool!

Hot Article

Hot Tools

MinGW - Minimalist GNU for Windows

MinGW - Minimalist GNU for Windows

This project is in the process of being migrated to osdn.net/projects/mingw, you can continue to follow us there. MinGW: A native Windows port of the GNU Compiler Collection (GCC), freely distributable import libraries and header files for building native Windows applications; includes extensions to the MSVC runtime to support C99 functionality. All MinGW software can run on 64-bit Windows platforms.

Dreamweaver Mac version

Dreamweaver Mac version

Visual web development tools

MantisBT

MantisBT

Mantis is an easy-to-deploy web-based defect tracking tool designed to aid in product defect tracking. It requires PHP, MySQL and a web server. Check out our demo and hosting services.

WebStorm Mac version

WebStorm Mac version

Useful JavaScript development tools

Zend Studio 13.0.1

Zend Studio 13.0.1

Powerful PHP integrated development environment