IIS7 部署 - 重复“system.web.extensions/scripting/scriptResourceHandler"部分

IIS7 deployment - duplicate #39;system.web.extensions/scripting/scriptResourceHandler#39; section(IIS7 部署 - 重复“system.web.extensions/scripting/scriptResourceHandler部分)
本文介绍了IIS7 部署 - 重复“system.web.extensions/scripting/scriptResourceHandler"部分的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

尝试在 IIS7 的默认应用程序池上部署 .net 3.5 网站并将框架部分设置为 4.0 时,我收到以下错误.

On attempting to deploy a .net 3.5 website on the default app pool in IIS7 having the framework section set to 4.0, I get the following error.

有一个重复system.web.extensions/scripting/scriptResourceHandler"部分已定义.

There is a duplicate 'system.web.extensions/scripting/scriptResourceHandler' section defined.

评论有问题的行也无济于事.关于我需要做什么或看什么的任何指示?

Commenting off the offending lines didn't help either. Any pointers on what I need to do or look at?

推荐答案

如果您的计划是部署到具有在 .net 4.0 中运行的应用程序池的 IIS,您将需要清理包含所有部分的 web.config指向 .net 3.5 的定义.失败的原因是因为这些节定义已经包含在 .NET 4.0 的根 web.config 中(请参阅 %windir%microsoft.netframeworkv4.0.30319configmachine.config),其中包括所有系统.web.extensions 已经声明.

If your plan is to deploy to an IIS that has an Application Pool running in .net 4.0 you will need to cleanup the web.config that includes all the section Definitions that point to .net 3.5. The reason this fails is because these section definitions are already included in the root web.config in .NET 4.0 (see %windir%microsoft.netframeworkv4.0.30319configmachine.config) that include all the system.web.extensions declared already.

另一个快速解决方法是将应用程序池设置为 2.0,就像您的开发机器看起来一样.

Another quick fix is to have the application pool set to 2.0 just as your development machine appears to have,.

这篇关于IIS7 部署 - 重复“system.web.extensions/scripting/scriptResourceHandler"部分的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持编程学习网!

本站部分内容来源互联网,如果有图片或者内容侵犯您的权益请联系我们删除!

相关文档推荐

c# Generic Setlt;Tgt; implementation to access objects by type(按类型访问对象的C#泛型集实现)
InvalidOperationException When using Context Injection in ASP.Net Core(在ASP.NET核心中使用上下文注入时发生InvalidOperationException)
how do i pass parameters to aspnet reportviewer(如何将参数传递给aspnet report查看器)
Bind multiple parameters from route and body to a model in ASP.NET Core(在ASP.NET Core中将路由和主体中的多个参数绑定到一个模型)
Custom model binding in AspNet Core WebApi?(AspNet Core WebApi中的自定义模型绑定?)
How to minify in .net core mvc view?(如何在.Net核心MVC视图中缩小?)