Enable display_errors In PHP

Enable display_errors In PHP

The web server by default do not have the display_errors turned on for PHP. This is due to the PHP engine by its default behavior to display out the full physical path of the script that is having error in the error message output. This will cause the script is being exposed to the Internet which may cause security threads.

Therefor, the display_errors is disabled.

For Windows

You may turn on the display error in your application by using the init_set() function which you may refer to the following command to each script.

ini_set('display_errors',1);
 

For Linux

You may turn it on using either :

1. Using init_set() in the application OR
2.
Alter the php.ini file by include the following line from your public_html folder:

display_errors=On

Add Feedback