使用IIS 8.5在本地计算机上运行ASP网站时出现问题 [英] Problem running ASP Website on Local Machine with IIS 8.5

查看:93
本文介绍了使用IIS 8.5在本地计算机上运行ASP网站时出现问题的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我使用Visual Studio 2015创建了一个网站。它主要是静态页面,但有一个aspx页面。整个事情在Visual Studio(调试模式)下运行良好,也在远程服务器上运行(我在发布时使用FTP)。



但是当我尝试将其发布到本地计算机上的文件夹并使用IIS运行时出现问题。它运行静态页面确定,但是当我转到aspx页面时会产生错误 -



HTTP错误404.3 - 未找到



由于扩展配置,无法提供您请求的页面。如果页面是脚本,请添加处理程序....



我按照说明(尽我所能)并为.aspx文件扩展名添加了托管处理程序。



System.Web.DefaultHttpHandler,System.Web,Version = 4.0.0.0,Culture = neutral,PublicKeyToken = b03f5f7f11d50a3a



同样的错误继续发生。我认为它必须是项目或IIS的一些配置问题,但我无法弄明白。有人可以帮助我吗?

I created a website using Visual Studio 2015. It has mostly static pages, but one aspx page. The whole thing runs fine under Visual Studio (debug mode) and also on the remote server (I used FTP when publishing it).

But when I tried to publish it to a folder on the local machine and run it with IIS there was a problem. It runs the static pages OK, but when I go to the aspx page an error is produced -

HTTP Error 404.3 - Not Found

The page you are requesting cannot be served because of the extension configuration. If the page is a script, add a handler....

I followed instructions (as best I could) and added a Managed Handler for .aspx file extensions.

System.Web.DefaultHttpHandler, System.Web, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a

The same error continues to occur. I think it must be some configuration issue with the project or IIS, but I can't figure it out. Could someone please help me?

推荐答案

Wombaticus - 感谢您的回复。我确实谷歌了,终于找到了解决方案。在打开或关闭Windows功能下的程序和功能中,然后在Internet信息服务下,我启用了以下内容 -



.NET可扩展性4.5

ASP.NET 4.5

ISAPI扩展

ISAPI过滤器



解决了问题。多么宽慰 - 我今天和这个问题争斗了好几个小时。我是ASP.net的新手,可以使用我能得到的所有帮助。



Victor
Wombaticus - thanks for the reply. I did google it and finally came upon a solution. In 'Programs and Features' under 'Turn Windows Features On or Off' and then under 'Internet Information Services' I enabled the following -

.NET Extensibility 4.5
ASP.NET 4.5
ISAPI Extensions
ISAPI Filters

It fixed the problem. What a relief - I was battling this problem for hours today. I'm new to ASP.net and can use all the help I can get.

Victor


这篇关于使用IIS 8.5在本地计算机上运行ASP网站时出现问题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆