1、安装了部分插件,造成后台打不开,提示500错误
【解决方案】删除不需要的插件,或者存在安全漏洞的插件,这样也是为你们的网站考虑。
2、网站首页或者其他页面只能通过.Php文件访问,其他情况下全部是500错误
【解决方案】这种情况是由于部分服务器或者主机设置了权限,大家可以参照下图通过FTP进行设置
3、在PHP不用版本显示500报错@session_register($this->keepUserIDTag)这种代码在PHP5.3以上版本直接报Fatal
error错误。
【原因分析】织梦不支持PHP5.3、PHP5.4及以上版本了,主要原为是php5.4的版本废除了session_register函数
这种方式处理完整代码如下$_SESSION[$this->keepUserIDTag]
= $this->userID
首先打开
include/userlogin.class.php这个文件,在287行到308行:
01.@session_register($this->keepUserIDTag)
02.$_SESSION[$this->keepUserIDTag] = $this->userID
03.@session_register($this->keepUserTypeTag)
04.$_SESSION[$this->keepUserTypeTag] = $this->userType
05.@session_register($this->keepUserChannelTag)
06.$_SESSION[$this->keepUserChannelTag] = $this->userChannel
07.@session_register($this->keepUserNameTag)
08.$_SESSION[$this->keepUserNameTag] = $this->userName
09.@session_register($this->keepUserPurviewTag)
10.$_SESSION[$this->keepUserPurviewTag] = $this->userPurview
11.@session_register($this->keepAdminStyleTag)
12.$_SESSION[$this->keepAdminStyleTag] = $adminstyle
13.PutCookie('DedeUserID', $this->userID, 3600 * 24, '/')
14.PutCookie('DedeLoginTime', time(), 3600 * 24, '/')
替换成下面的
01.//@session_register($this->keepUserIDTag)
02.$_SESSION[$this->keepUserIDTag] = $this->keepUserIDTag
03.$_SESSION[$this->keepUserIDTag] = $this->userID
04.//@session_register($this->keepUserTypeTag)
05.$_SESSION[$this->keepUserTypeTag] = $this->keepUserTypeTag
06.$_SESSION[$this->keepUserTypeTag] = $this->userType
07.// @session_register($this->keepUserChannelTag)
08.$_SESSION[$this->keepUserChannelTag] = $this->keepUserChannelTag
09.$_SESSION[$this->keepUserChannelTag] = $this->userChannel
10.//@session_register($this->keepUserNameTag)
11.$_SESSION[$this->keepUserNameTag] = $this->keepUserNameTag
12.$_SESSION[$this->keepUserNameTag] = $this->userName
13.//@session_register($this->keepUserPurviewTag)
14.$_SESSION[$this->keepUserPurviewTag] = $this->keepUserPurviewTag
15.$_SESSION[$this->keepUserPurviewTag] = $this->userPurview
16.// @session_register($this->keepAdminStyleTag)
17.$_SESSION[$this->keepAdminStyleTag] = $this->keepAdminStyleTag
18.$_SESSION[$this->keepAdminStyleTag] = $adminstyle
19.PutCookie(‘DedeUserID’, $this->userID, 3600 * 24, ‘/’)
20.PutCookie(‘DedeLoginTime’, time(), 3600 * 24, ‘/’)
4、如果网页文件确实不存在,可通过FTP或登陆服务器查看报错的文件是否存在,如存在,则检查上面两种。
5、后台管理界面出现500错误提示
【解决方案】这是程序文件错误。可以检查下后台文件,在管理目录dede文件下的文件没有修改的话建议重新下载一个dede文件夹,再把dede文件夹覆盖一下
今天把系统换成了windows server 2008 r2 同时将PHP环境提升至PHP5.7版本,测试PHPinfo的时候一点问题都没有,但是登陆dede后台却显示500错误,这应该怎么解决呢?百度了一下发现dede不支持PHP5.3、PHP5.4及以上版本了,主要原为是php5.4的版本废除了session_register函数可以采用如$_SESSION[$this->keepUserIDTag] = $this->userID
这种方式处理完整代码如下
首先打开 include/userlogin.class.php这个文件,在287行到308行原内容如下:
@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, ‘/’)
替换成
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, ‘/’)
教程来源:http://www.dede58.com/a/zhimengjiaocheng/dedefault/2949.html
500 - 内部服务器错误。500.12 - 应用程序正忙于在 Web 服务器上重新启动。
500.13 - Web 服务器太忙。
500.15 - 不允许直接请求 Global.asa。
500.16 – UNC 授权凭据不正确。这个错误代码为 IIS 6.0 所专用。
500.18 – URL 授权存储不能打开。这个错误代码为 IIS 6.0 所专用。
500.100 - 内部 ASP 错误。
501 - 页眉值指定了未实现的配置。
502 - Web 服务器用作网关或代理服务器时收到了无效响应。
502.1 - CGI 应用程序超时。
502.2 - CGI 应用程序出错。application.
503 - 服务不可用。这个错误代码为 IIS 6.0 所专用。
504 - 网关超时。
505 - HTTP 版本不受支持。云修网,故障解决
欢迎分享,转载请注明来源:夏雨云
评论列表(0条)