MVC部署出现403.14问题记录

1、问题截图

  

2、解决办法2种

  1)在system.webServer下增加,这种是不推荐的。

<modules runAllManagedModulesForAllRequests="true" />

  2)添加modules节点

<modules>
  <remove name="UrlRoutingModule-4.0" />
<remove name="BundleModule" />
<add name="BundleModule" type="System.Web.Optimization.BundleModule" />
  <add name="UrlRoutingModule-4.0" type="System.Web.Routing.UrlRoutingModule" 

preCondition="" />
  <!-- any other modules you want to run in MVC e.g. FormsAuthentication, Roles 

etc. -->
</modules>

参考地址:

  http://www.britishdeveloper.co.uk/2010/06/dont-use-modules-runallmanagedmodulesfo.html

  http://www.cnblogs.com/xishuai/archive/2015/01/06/Styles-Render-runAllManagedModulesForAllRequests-true.html

猜你喜欢

转载自www.cnblogs.com/zhaoyihao/p/9617781.html
今日推荐