The solution to the problem that apache does not have php.ini: 1. Download PHP and add the code that introduces php in the apache configuration file httpd.conf; 2. Rename the "php.ini-development" file to php. ini; 3. Restart apache.
The operating environment of this article: windows7 system, php7.0.24 version, DELL G3 computer
What should I do if apache does not have php.ini?
PHP under windows does not need to be installed. Download one version of php (such as php7.0.24) from the official website, unzip it and put it in a folder (such as c:/php), and then Add the code that introduces php to the apache configuration file httpd.conf:
<IfModule mime_module> AddType application/x-httpd-php .php LoadModule php7_module "c:/php/php7apache2_4.dll" PHPIniDir "c:/php" </IfModule>
Then rename the php.ini-development file in the php folder to php.ini and restart apache.
Recommended learning: "PHP Video Tutorial"
The above is the detailed content of What should I do if apache does not have php.ini?. For more information, please follow other related articles on the PHP Chinese website!