ASP.NET MVC 4 Web.config错误

时间:2014-06-24 17:59:40

标签: asp.net asp.net-mvc

我确信这是一件非常简单的事情。当我运行我的ASP Web应用程序时,它在浏览器中出现以下错误:

Server Error in '/' Application.

Configuration Error

Description: An error occurred during the processing of a configuration file
required to service this request. Please review the specific error details
below and modify your configuration file appropriately. 

Parser Error Message: Unrecognized element.

Source Error: 

Line 23:   <system.web>  ## This line is highlighted in red ##
Line 24:       <identity impersonate="true"/>
Line 25:       <compilation debug="true" targetFramework="4.5" />

这是我的Web.config中我收到错误的部分。

...
<appSettings>
  <add key="webpages:Version" value="3.0.0.0" />
  <add key="webpages:Enabled" value="false" />
  <add key="ClientValidationEnabled" value="true" />
  <add key="UnobtrusiveJavaScriptEnabled" value="true" />
</appSettings>
<system.web>
  <identity impersonate="true"/>
  <compilation debug="true" targetFramework="4.5" />
  <httpRuntime targetFramework="4.5" />
</system.web>
<system.webServer>
  <validation validateIntegratedModeConfiguration="false" />
...

0 个答案:

没有答案