如何在IIS7.5中启用ASP经典
我在 Windows 7 中运行 IIS 7.5,并且已经进入“打开或关闭 Windows 功能”并在“Internet 信息服务/万维网服务/应用程序开发功能”中启用了 ASP。完成此操作后,我开始收到 HTTP 404 错误:
由于扩展名,无法提供您请求的页面
配置。如果页面是脚本,请添加处理程序。如果文件应该是
下载后,添加 MIME 映射。
所以我认为这意味着我需要在处理程序映射中添加到 *.asp 的映射,并将处理程序映射到 C:\Windows\System32\inetsrv\asp.dll。但是当我尝试加载页面时,我收到服务器错误消息:
无法加载类型“C:\Windows\system32\inetsrv\asp.dll”。
有谁知道这里发生了什么或如何处理这个问题?
我应该提到的另一件事是,我已经在应用程序池中启用了 32 位应用程序,并将 ASP 设置为向浏览器发送错误,但这些都没有解决问题或为我提供更多信息。
请注意,这是 ASP Classic,而不是 ASP.NET,ASP.NET 对我来说工作得很好。
I am running IIS 7.5 in Windows 7 and have already gone into "Turn Windows features on or off" and enabled ASP in "Internet Information Services/World Wide Web Service/application Development Features". Once I did that I started getting an HTTP 404 error saying:
The page you are requesting cannot be served because of the extension
configuration. If the page is a script, add a handler. If the file should be
downloaded, add a MIME map.
So I took this to mean that I needed to add a mapping to *.asp in the Handler mappings and the handler is mapped to C:\Windows\System32\inetsrv\asp.dll. But when I try to load the page I get a server error saying:
Could not load type 'C:\Windows\system32\inetsrv\asp.dll'.
Does anyone know what is going on here or how to handle this?
One other thing I should mention is that I have already enabled 32-Bit application in my Application pool and set ASP to send errors to browser, but neither of those things has resolved the issue or given me more information.
Please note this is ASP Classic not ASP.NET, ASP.NET is working just fine for me.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(6)
单击“确定”,您的网站将正确加载。
Click ok and your web sites will load properly.
如果您在 Windows Server 2012 上运行 IIS 8,则需要执行以下操作:
从那时起完成,您的应用程序应该开始运行
If you are running IIS 8 with windows server 2012 you need to do the following:
from then on your application should start running
事实证明,如果我在网站和应用程序级别添加处理程序映射,一切都会完美运行。我只是在服务器级别添加它们,因此 IIS 不知道将 asp 页面映射到 IsapiModule。
因此,要解决此问题,请转到要添加应用程序的网站,然后双击“处理程序映射”。单击“添加脚本映射”并输入以下信息:
RequestPath: *.asp
可执行文件:C:\Windows\System32\inetsrv\asp.dll
名称:Classic ASP(可以是您想要的任何名称)
So it turns out that if I add the Handler Mappings on the Website and Application level, everything works beautifully. I was only adding them on the server level, thus IIS did not know to map the asp pages to the IsapiModule.
So to resolve this issue, go to the website you want to add your application to, then double click on Handler Mappings. Click "Add Script Map" and enter in the following information:
RequestPath: *.asp
Executable: C:\Windows\System32\inetsrv\asp.dll
Name: Classic ASP (this can be anything you want it to be
我在这里找到了一些详细说明: http://digitallibraryworld.com/?p=6
关键部分建议似乎是,如果您已将应用程序池配置为运行 32 位应用程序,则不要使用 64 位 ASP.DLL(在 system32 中找到)(而是使用 32 位 ASP.DLL)。
当然,如果您不需要加载任何 32 位库(或数据提供程序等),只需运行 64 位 ASP.DLL 让您的生活更轻松!
I found some detailed instructions here: http://digitallibraryworld.com/?p=6
The key piece of advice seems to be, don't use the 64-bit ASP.DLL (found in system32) if you've configured the app pool to run 32-bit applications (instead, use the 32-bit ASP.DLL).
Of course, if you don't need to load any 32-bit libraries (or data providers, etc.), just make your life easier by running the 64-bit ASP.DLL!
如果您在 Windows Server 2008 上遇到上述问题,您可能需要启用 ASP。为此,请按照下列步骤操作:
添加“应用程序服务器”角色:
然后,添加“Web服务器”角色:
更多信息:
If you get the above problem on windows server 2008 you may need to enable ASP. To do so, follow these steps:
Add an 'Application Server' role:
Then, add a 'Web Server' role:
More info:
http://www.iis.net/learn/application-frameworks/running-classic-asp-applications-on-iis-7-and-iis-8/classic-asp-not-installed-by-default-on-iis
使经过身份验证的用户组可以访问该文件。右键单击您的虚拟目录,并授予该组对经过身份验证的用户的读/写访问权限。
我在 Windows 10 机器上遇到问题。
Make the file accessible to the Authenticated Users group. Right click your virtual directory and give the group read/write access to Authenticated Users.
I faced issue on windows 10 machine.