IIS 10 - 未找到文件或目录

Sta*_*her 7 .net iis http-status-code-404 server

我有一个在 Visual Studio 中制作的网络应用程序。每当我导航到它时,我都会收到 404。我可以访问例如:“xyz.net/res/image.png”,但是我不能“default.aspx”。

默认文档: 默认文档

捆绑: 捆绑

应用程序池: 应用程序池

当我导航到端口 80 上的本地主机时,会发生这种情况: 当我导航到端口 80 上的本地主机时,会发生这种情况。

我之前已经使用 IIS 设置并运行了一个 Web 服务器,但从那以后我重新安装了 Windows,但我无法弄清楚。在我修改它之前,我可以访问本地主机。文件路径似乎是正确的,但我认为否则无法访问 png 文件。任何帮助表示赞赏。

小智 7

还有其他人在这个问题上苦苦挣扎。修复方法是在 Windows 控制面板下的“打开/关闭 Windows 功能”下启用应用程序开发。

Administrators should instead install/uninstall ASP.NET 4.5 with IIS8 using the "Turn 
Windows Features On/Off" dialog,  the Server Manager management tool, or the dism.exe 
command line tool.  For more details please see http://go.microsoft.com/fwlink/?LinkID=216771.
Run Code Online (Sandbox Code Playgroud)

打开 ASP.NET

我附上了一张屏幕截图,显示在 Web 服务器 IIS > 应用程序开发下可以找到 ASP.NET 功能。

希望这可以帮助任何在尝试执行 .aspx 页面时收到 404 错误消息的人。