获取“WebResource.axd 处理程序必须在配置中注册才能处理此请求。”错误

发布于 2024-08-28 19:19:15 字数 587 浏览 5 评论 0原文

我在 IIS7 上运行 ASP.NET 应用程序时收到此错误。我已经尝试按照它所说的去做,但没有帮助。

WebResource.axd 处理程序必须是 在配置中注册到 处理此请求。

> <!-- Web.Config Configuration File -->
> 
> <configuration>    
>     <system.web>
>        <httpHandlers>
>            <add path="WebResource.axd" verb="GET" type="System.Web.Handlers.AssemblyResourceLoader" validate="True" />
>        </httpHandlers>    
>     </system.web> 
> </configuration>

我正在使用一点 AJAX,我认为这就是导致问题的原因。以前有人遇到过这种情况吗?

I'm getting this error while running my ASP.NET app on IIS7. I've tried doing what it says to do but it doesn't help.

The WebResource.axd handler must be
registered in the configuration to
process this request.

> <!-- Web.Config Configuration File -->
> 
> <configuration>    
>     <system.web>
>        <httpHandlers>
>            <add path="WebResource.axd" verb="GET" type="System.Web.Handlers.AssemblyResourceLoader" validate="True" />
>        </httpHandlers>    
>     </system.web> 
> </configuration>

I'm using a little bit of AJAX which is what I think is causing the issue. Has anyone encountered this before?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(6

如此安好 2024-09-04 19:19:15

我想通了,所以出于搜索原因我将其发布在这里。这是 ASP.NET 中的一个错误,与安装 ColdFusion 有关。微软尚未发布修复程序。

有两种方法可以解决这个问题。

  1. 将 IIS7 中的 AppPool 更改为“Classic .NET AppPool”。我不确定此设置是否有任何影响。

  2. 从 system32\inetsrv\config 中的 applicationHost.config 文件中删除对 ColdFusion 的所有引用。

I figured it out so I'm posting it here for search reasons. It is a bug in ASP.NET and it has to do with having ColdFusion installed. Microsoft hasn't yet released a fix.

There are two ways to fix this.

  1. Change the AppPool in IIS7 to "Classic .NET AppPool". I'm not sure of any implications with this setting.

  2. Remove all the references to ColdFusion from your applicationHost.config file in system32\inetsrv\config.

回忆那么伤 2024-09-04 19:19:15

ColdFusion 安装了一个全局通配符处理程序映射,它显然覆盖了许多标准 .NET 处理程序。提到的解决方案工作得很好,但如果您无法切换到经典模式并且不想破坏 ColdFusion 安装,则可以在单个站点级别删除继承的处理程序映射。

为此,请转到 IIS 中的相关站点,双击“IIS”部分下的“处理程序映射”,然后找到名为“AboMapperCustom-XXXXXX”且路径为“*”的处理程序。选择该条目并单击侧栏中的“删除”。这只会删除应用程序的映射,因此不会破坏服务器上任何现有的 CF 站点。

ColdFusion installs a global wildcard handler mapping which apparently overrides many of the standard .NET handlers. The solutions mentioned work just fine, but if you can't switch to Classic Mode and don't want to screw with your ColdFusion installation, you can remove the inherited handler mapping at the individual site level.

To do this, go to the site in question in IIS, double-click on "Handler Mappings" under the "IIS" section, and find the handler named something like "AboMapperCustom-XXXXXX" with "*" for the Path. Select the entry and click "Remove" in the sidebar. This will only remove the mapping for your application, so it won't break any existing CF sites on the server.

朕就是辣么酷 2024-09-04 19:19:15

我在一对集群服务器之间不小心复制了应用程序的 web.config 后遇到了这个错误,这覆盖了标签:

<system.webServer>
    <handlers>
        <remove name="AboMapperCustom-XXXXXXXX" />
    </handlers>
</system.webServer>

根据

<system.webServer>
    <handlers>
        <remove name="AboMapperCustom-YYYYYYYY" />
    </handlers>
</system.webServer>

Josh 的响应查找正确的 ID 并更正标签修复了它,但更重要的是,可能会保留该处理程序映射从偷偷溜回来。

I got this error after carelessly copying my app's web.config between a pair of clustered servers, which overwrote the tag:

<system.webServer>
    <handlers>
        <remove name="AboMapperCustom-XXXXXXXX" />
    </handlers>
</system.webServer>

with

<system.webServer>
    <handlers>
        <remove name="AboMapperCustom-YYYYYYYY" />
    </handlers>
</system.webServer>

Locating the proper ID as per Josh's response and correcting the tag fixed it, but more importantly, will presumably keep that handler mapping from sneaking back in.

追我者格杀勿论 2024-09-04 19:19:15

我在未安装 ASP.NET 4.6 的新 Windows 2016 服务器上发生了此问题。安装后一切都修复了。

步骤

- Run Server Manager
- Manage > Add Roles and Features 
- Server Roles
- Web Server (IIS) > Web Server > Application Development > ASP.NET 4.6

在此处输入图像描述

The issue happened to me on new Windows 2016 server where ASP.NET 4.6 was not installed. After installation everything got fixed.

Steps

- Run Server Manager
- Manage > Add Roles and Features 
- Server Roles
- Web Server (IIS) > Web Server > Application Development > ASP.NET 4.6

enter image description here

萌无敌 2024-09-04 19:19:15

在 IIS7 中,您需要将 部分添加到 而不是 。这是示例

In IIS7 you need to add the <httpHandler> section to <system.webServer> instead of <system.web>. Here is an example.

李白 2024-09-04 19:19:15

我遇到了这个问题,原因是当 IIS 应用程序池处于集成模式时,Coldfusion 与 ASP.NET 应用程序的某些配置之间不兼容。 Coldfusion 必须被禁用。

I had this problem and that reason was incompatibility between Coldfusion and some configurations of ASP.NET applications when IIS App pool is in integrated mode. Coldfusion must be disable .

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文