IIS7 deployment - duplicate #39;system.web.extensions/scripting/scriptResourceHandler#39; section(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"部分的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持编程学习网!
本文标题为:IIS7 部署 - 重复“system.web.extensions/scripting/scriptResourceHandler"部分


基础教程推荐
- 将事件 TextChanged 分配给表单中的所有文本框 2022-01-01
- 全局 ASAX - 获取服务器名称 2022-01-01
- JSON.NET 中基于属性的类型解析 2022-01-01
- 从 VS 2017 .NET Core 项目的发布目录中排除文件 2022-01-01
- 在 VS2010 中的 Post Build 事件中将 bin 文件复制到物 2022-01-01
- 如何动态获取文本框中datagridview列的总和 2022-01-01
- 经典 Asp 中的 ResolveUrl/Url.Content 等效项 2022-01-01
- 错误“此流不支持搜索操作"在 C# 中 2022-01-01
- 首先创建代码,多对多,关联表中的附加字段 2022-01-01
- 是否可以在 asp classic 和 asp.net 之间共享会话状态 2022-01-01