Web Hosting

Please find below our list of Web Hosting guides to help with your hosting account.

How to display PHP run-time errors

This article was posted in: Web Hosting

This article will show you show to display your script's errors at run-time.

By default, the php.ini setting display_errors is turned off on all of our servers. This is for your own security, because if a script encounters an error then the problem will be displayed to the public. This is a serious security concern as it may potentially expose sensitive data.


How to re-enable display_error

Most websites load a configuration file or header file before anything else. Quite often, this is called index.php and it lives in the public_html directory. Simply add the following lines of code immediately after the opening <?php tag

ini_set('display_errors',1);
ini_set('error_reporting', E_ALL); // Add this line if you want to show even the slightest problem!