I want to execute a PHP file when an error 500 is reported in IIS. Setting a custom error file is easy. The problem is how do I make the PHP file receive the error details to process them?
For example, I want to display:
- What is the error message.
- What file caused the error.
- Which line caused the error.
Example of the processing file:
<?php
echo $_GET["errorfile"];
echo "<br/>";
echo $_GET["errordetails"];
?>
I'm using Windows 10 Home, IIS version 10.0.17763.1, PHP version 7.3.0 via FastCGI.