Web.config 1.9 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253
  1. <?xml version="1.0"?>
  2. <configuration>
  3. <appSettings/>
  4. <connectionStrings/>
  5. <!--
  6. 有关 web.config 更改的说明,请参见 http://go.microsoft.com/fwlink/?LinkId=235367。
  7. 可在 <httpRuntime> 标记上设置以下特性。
  8. <system.Web>
  9. <httpRuntime targetFramework="4.5" />
  10. </system.Web>
  11. -->
  12. <system.web>
  13. <compilation debug="true" targetFramework="4.5"/>
  14. <!--
  15. 通过 <authentication> 节,可配置
  16. ASP.NET 用于识别进入用户的
  17. 安全身份验证模式。
  18. -->
  19. <authentication mode="Windows"/>
  20. <!--
  21. 通过 <customErrors> 节,可以配置
  22. 在执行请求的过程中出现未处理的错误时要执行
  23. 的操作。具体而言,
  24. 开发人员通过该节可配置要显示的 html 错误页,
  25. 以代替错误堆栈跟踪。
  26. <customErrors mode="RemoteOnly" defaultRedirect="GenericErrorPage.htm">
  27. <error statusCode="403" redirect="NoAccess.htm" />
  28. <error statusCode="404" redirect="FileNotFound.htm" />
  29. </customErrors>
  30. -->
  31. <pages controlRenderingCompatibilityVersion="3.5" clientIDMode="AutoID"/>
  32. </system.web>
  33. <!--
  34. system.webServer 节是在 Internet Information Services 7.0 下运行 ASP.NET AJAX
  35. 所必需的。对于早期版本的 IIS,不必保留此节。
  36. -->
  37. <system.webServer>
  38. <staticContent>
  39. <remove fileExtension=".less"/>
  40. <mimeMap fileExtension=".less" mimeType="text/css"/>
  41. <remove fileExtension=".mp4"/>
  42. <mimeMap fileExtension=".mp4" mimeType="video/mp4"/>
  43. <remove fileExtension=".flv"/>
  44. <mimeMap fileExtension=".flv" mimeType="video/x-flv"/>
  45. <remove fileExtension=".lghp"/>
  46. <mimeMap fileExtension=".lghp" mimeType="text/html"/>
  47. <remove fileExtension=".json"/>
  48. <mimeMap fileExtension=".json" mimeType="text/json"/>
  49. </staticContent>
  50. </system.webServer>
  51. </configuration>