Modify php. ini to block the error message. this is because the error display is disabled in php. ini and the error is written as a file. this is a result set by humans, and display_errorson is enough. However, the error is not displayed. we recommend that you enable it during debugging and disable it when providing services. Provide you with some information: display_errorsOnphp displays the error message by default. we will change it to display_er to modify php. ini to shield the error message.
This is because the error display is disabled in php. ini and the error is written as a file. this is the result of human setting. display_errors = on.
However, the error is not displayed. we recommend that you enable it during debugging and disable it when providing services.
Provide you with some information:
Display_errors = On
By default, the error message is displayed in php. we will change it:
Display_errors = Off
After the error display is disabled, the php function execution error information will not be displayed to the user. This will prevent attackers from learning the physical location of the script from the error information to a certain extent, as well as some other useful information, at least it may cause some obstacles to the attacker's black box detection. These error messages may be useful to us and can be written to a specified file. modify the following:
Log_errors = Off
Changed:
Log_errors = On
And the specified file. find the following line:
; Error_log = filename
Remove the comment and change filename to the specified file, such as/usr/local/apache/logs/php_error.log.
Error_log =/usr/local/apache/logs/php_error.log
In this way, all errors will be written to the php_error.log file.