Jquery中文网 www.jquerycn.cn
Jquery中文网 >  脚本编程  >  php  >  正文 iis php提示An error occurred on the server when processing the URL

iis php提示An error occurred on the server when processing the URL

发布时间:2018-10-17   编辑:www.jquerycn.cn
jquery中文网为您提供iis php提示An error occurred on the server when processing the URL等资源,欢迎您收藏本站,我们将为您提供最新的iis php提示An error occurred on the server when processing the URL资源
使用iis php环境经常会碰到iis php提示An error occurred on the server when processing the URL错误了,但是在php官网也找不到很好的解决办法。

在几天前帮朋友处理网站搬家后出现的MSSQL数据库链接问题,后来我把它的代码在本地搭建环境测试就发现一个ASP的问题并此解决了,也帮助我朋友解决了问题。所以今天给大家讲下ASP出现的一个错误,虽然ASP的程序已经很少人使用了,但是还是不少的。

  好的,进入我们的主题,首先我们先了解下演示的环境。首先我使用的是Windows 7 旗舰版 32bit 和IIS7.5 的版本。程序是使用了一个简单的CMS系统,语言:ASP。

An error occurred on the server when processing the URL. Please contact the system administrator.

出现的错误是:
An error occurred on the server when processing the URL. Please contact the system administrator.
If you are the system administrator please click here to find out more about this error.

  其实解决这个问题很简单,今天就把它当一节课与大家讲讲。

第一步:启动IIS,打开该站点。在【功能视图】的列表中找到【ASP】

第一步:启动IIS,打开该站点。在【功能视图】的列表中找到【ASP】

第二步:找到【将错误发送到浏览器】的值修改为【<span style="color: #e53333">True</span>】并应用。

第二步:找到【将错误发送到浏览器】的值修改为【True】并应用。

如果你修改之后,直接预览再看效果。估计是不行的,因为还没有设置好。

Active Server Pages 错误 \'ASP 0131\'

出现的错误如下
Active Server Pages 错误 'ASP 0131'
不允许的父路径
/admin/login.asp,行 1
包含文件“../Inc/Const.Asp”不能用“..”表示父目录。

 

第三步:这时候我还要设置下【启用父路径】,同样设置为【<span style="color: #e53333">True</span>】并应用

第三步:这时候我还要设置下【启用父路径】,同样设置为【True】并应用

再看下效果如何吧?

完成

  顺便也在这里解释下,而我根据我理解来介绍呢,简单来说呢?将错误发送到浏览器就是把程序错误信息不用友好的方式展现出来,主要是为了方便调试;启用父路径而是代码中出现了“...”等的路径方式,跟Windows权限继承是一样的。下面内容来自微软官方说明:
将错误发送到浏览器 [scriptErrorSentToBrowser]:
指定 Web 服务器除了将调试详细信息(文件名、错误、行号、描述)记录到 IIS 请求日志中以外,是否还将其写入客户端浏览器。默认值为 True。
启用父路径 [enableParentPaths]:
指定 ASP 页是否允许相对于当前目录的路径(使用“...”表示法),即当前目录之上的路径。默认值为 False。

Tisp:
1.如果浏览器打开任何网站出现问题,可以把IE的【显示友好http错误信息】不要打勾启用来查看此网站的错误信息。

显示友好http错误信息

2.虚拟主机空间的用户可以让服务商来解决此问题。

您可能感兴趣的文章:
iis php提示An error occurred on the server when processing the URL
nodejs中使用mysql数据库的示例
Apache Reference Manual (9)
Apache Reference Manual (8)
IOCP Thread Pooling in C
Apache Reference Manual (4)
Server Error in '/' Application.
asp Provider 错误 '80004005'解决办法
一个好用的php mysql连接类
Apache Reference Manual (12)

[关闭]