500 Error With PHP and Webmatrix Shows "Friendly" Error Page
Asked Answered
M

2

10

I am working on a PHP application using IIS Express/Web Matrix and it is giving me the "friendly" error page instead of the actual error. How do I configure my site or IIS express to give me the actual error?

Memorable answered 17/9, 2011 at 20:37 Comment(0)
T
18

I know this is an oldish question but I had the same problem recently so I thought I would share how I got it working.

I just edited the php.ini file located at "C:\Program Files (x86)\IIS Express\PHP\v5.3" on my machine and change the line

display_errors = Off

to

display_errors = On

I also set

display_startup_errors = On

as well just to make sure.

Also if you right click the Web Matrix icon in the system tray and click "Show All Applications" then select your site there is a link the the applicationHost.config file that it uses so you can change settings in there.

Hope this helps some people!

Taitaichung answered 23/10, 2011 at 22:13 Comment(0)
K
4

If you've followed the advice of Mr. Adnams and still aren't seeing your own output for 403 and 500 errors, try adding an errorMode="Detailed" attribute to the httpErrors element within the web.config file found in your web root folder. If you don't already have a web.config file, start with this:

<?xml version="1.0" encoding="UTF-8"?>
<configuration>
  <system.webServer>
    <httpErrors errorMode="Detailed" />
  </system.webServer>
</configuration>
Kudu answered 27/12, 2012 at 21:24 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.