I'm writing a script in PHP5 that requires the code of certain files. When A file is not available for inclusion, first a warning and then a fatal error are thrown. I'd like to print an own error message, when it was not possible to include the code. Is it possible to execute one last command, if requeire did not work? the following did not work:
require('fileERROR.php5') or die("Unable to load configuration file.");
Supressing all error messages using error_reporting(0)
only gives a white screen, not using error_reporting gives the PHP-Errors, which I don't want to show.