So if the PHP script doesn't report syntax errors, what is the reason:
1. The general integration environment, the default will open error reporting; But in Linux, it doesn't have to be installed with a package,
At this point you can view the PHP configuration file and turn on Error reporting =>
Copy Code code as follows:
Display_errors = ON/* PHP configuration file path:/uer/local/php/etc/php.ini * *
Note:
method of dynamically setting php.ini configuration file in PHP script=>
Copy Code code as follows:
Ini_set (' display_errors ', ' on '); /* Show all errors/*
2. Set the error reporting level=>
Copy Code code as follows:
error_reporting = E_all; /* The most stringent error reporting level, the development phase can be opened * *
error_reporting = E_all &~ e_notice/* ERROR other than NOTICE * *
error_reporting = E_error | E_parse | E_core_error/* Only considers fatal Run-time errors, new parse errors and core errors * *
Above three kinds, recommend middle of.
Note:the method for dynamically setting error_reporting error reporting levels in PHP scripts =>
Copy Code code as follows:
Error_reporting (E_all &~ e_notice);
3. After changing the configuration file, you need to restart the service to take effect=>
Apache Startup:/usr/local/apache2/bin/apachectl Start/* Recommendation * *
Another, Red Hat Linux proprietary boot command: Service httpd start
Apache reboot:/usr/local/apache2/bin/apachectl restart
Another, Red Hat proprietary start command: Service httpd restart
Apache STOP:/usr/local/apache2/bin/apachectl stop
Another, Red Hat proprietary start command: Service httpd stop
Nginx reboot:/usr/local/nginx/sbin/nginx-s Reload/* Smooth reboot * *