When a php blank page appears, how to check the error message reported by php? The specific method is as follows: 1. Set the error level of php by configuring the parameters in php.ini You can add a line to the appropriate location in php.ini error_reporting = e_all Note: There are some examples in php.ini. For example, the local php.ini has the following code
Just in Below these lines of code add: error_reporting = e_all Then restart the web service. 2. Set the php error reporting level through the php function error_reporting (applicable to virtual hosts) If you do not have permission to modify the parameter configuration in php.ini, you can use this function to set the error level. How to use the error_reporting() function error_reporting(report_level) If the parameter level is not specified, the current error level will be returned. Any number of the above options can be "or" connected (using or or |) to report all required error levels. For example, the following code turns off user-defined errors and warnings, performs some actions, and then returns to the original error level:
Then you can put in the include/common.inc.php file in the forum:
and save it, so you can see the error message reported by php. php displays blank page 1. In iis manager --> "web service extension" ---> add php extension 2. The error prompts of php are blocked. In this way, if an error occurs, you will not see the prompts and the page will be blank. It is recommended to set this in php.ini.
|