For some inexplicable reason my PHP wont display errors. I have been writing a script that I am now testing and debugging but all I get is a white page even when I stick an echo 1; on line 1. At the top of my document I have the following error overrides to try and get errors to display:
ini_set("display_errors", 1);
ini_set("track_errors", 1);
ini_set("html_errors", 1);
error_reporting(E_ALL);
I can’t change the global php.ini file as this would override the settings for other live sites.
Try to include failing script in another php file like:
EDIT
Short explanation:
If main script contains for example syntax error and environment has error reporting turned off, then even if in main script we’ll enable error reporting then it won’t success as script won’t be executed (because of syntax error). Small trick described above allows to enable error reporting and see the error.