1. 事实上,我们都知道设置php显示错误,但是在iis7/7.5下,还需要额外的配置。首先看php的配置:

     

    display_errors = on;

    error_reporting = E_ALL & ~E_NOTICE;

     

     

  2.  

    iis的配置, 注意你首先需要在你的网站根目录添加web.config文件:

    代码如下:

     

    <?xml version="1.0" encoding="UTF-8"?>

    <!--

      For more information on how to configure your ASP.NET application, please visit

     

    http://go.microsoft.com/fwlink/?LinkId=169433

     

      -->

    <configuration>

      <system.web>

        <compilation debug="true" targetFramework="4.5"/>

        <httpRuntime targetFramework="4.5"/>

      </system.web>

      <system.webServer>

        <httpErrors errorMode="DetailedLocalOnly" existingResponse="PassThrough"></httpErrors>

      </system.webServer>

    </configuration>

     

     

     这个还真实百度经验的干货。。

相关文章:

  • 2021-08-27
  • 2021-05-22
  • 2022-12-23
  • 2023-03-25
  • 2022-01-14
  • 2022-12-23
  • 2022-01-25
猜你喜欢
  • 2021-06-01
  • 2022-12-23
  • 2021-10-05
  • 2021-10-04
相关资源
相似解决方案