Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I've tried the previously answered questions regarding this to no avail.

Just installed PHP5 and IIS on my Windows 7 machine and I'm having trouble getting PHP Errors displayed instead of 500 Errors.

In PHP;

error_reporting = E_ALL
display_errors = On

In IIS I have htmlErrors set to Detailed which shows a detailed IIS 500 Error page. If set to Custom it shows a basic 500 Error page.

If I set it to PassThrough I get a blank page (view-source reveals no code).

My PHP log file is showing a Fatal PHP Runtime Error.

share|improve this question

2 Answers 2

Are you using the rewrite module in IIS by any chance?

I have found that the rewrite module tends to screw with the PHP errors always forcing them to ERROR500 instead of showing me the code issue.

If you are comment out the rewrite code in the web.config of the site and do your testing.

share|improve this answer

Double click "ASP" in the sites Home screen in IIS admin, expand "Debugging Properties" and enable "Send errors to browser" and click "Apply".

Under "Error Pages" on the home screen select "500", then "Edit feature settings" and select "Detailed Errors".

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.