English | 简体中文 | 繁體中文 | Русский язык | Français | Español | Português | Deutsch | 日本語 | 한국어 | Italiano | بالعربية
Generally, after Apache installs php, the default loading location of the php configuration file is in php/lib/folder, if there is no php.ini file in the folder, Apache will not be able to find the php configuration file. In this case, there are two methods:
The first method is:It is to copy a configuration file of the same version of php to the default loading folder, so the configuration in this configuration file will be applied at this time.
The second method is:It is to specify the location of an existing php.ini. The specific method is as follows:
(Add PHPIniDir at the last line of the httpd.conf file) /usr/local/lib/php.ini )
As shown in the following figure:
The Apache configuration after modification is as follows:
By accessing a meaning output phpinfo (You can view the php file in the )
This article explains how to modify the Apache configuration to specify the location of the php configuration file php.ini, which is all the editor shares with everyone. I hope it can be a reference for everyone, and I also hope everyone will support the Shouting Tutorial.