Home  >  Article  >  Backend Development  >  What to do if modifying php.ini is invalid

What to do if modifying php.ini is invalid

藏色散人
藏色散人Original
2020-11-01 14:20:412493browse

Solution to invalid modification of php.ini: First execute the command "php -i | grep "php.ini""; then modify the configuration in the php.ini file to "display_errors=On"; finally restart nginx and php-fpm will do.

What to do if modifying php.ini is invalid

Recommended: "PHP Video Tutorial"

Solution to invalid modification of php.ini configuration file

1. Determine whether the modified php.ini file is a loaded file. Use the command:

php -i | grep "php.ini"

2. The configuration of the php-fpm.conf file can override the configuration of the php.ini file.

For example, modify the configuration display_errors=On in the php.ini file. If the configuration in the php-fpm.conf file is: php_flag[display_errors] = off, the configuration will not take effect.

3. Remember to restart nginx and php-fpm

The above is the detailed content of What to do if modifying php.ini is invalid. For more information, please follow other related articles on the PHP Chinese website!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn