1.Apache installation
Modify the http.conf file under the Apache24conf folder:
(1) Modify the root path of ServerRoot Apache
The default is ServerRoot "c:/Apache24", modify it to: ServerRoot "D: /phpEnv/Apache24" (that is, the folder where you decompressed it)
to “ServerName” Needed for Apache. O (3) Modify the main folder directory interviewed by Documentroot Apache (ie PHP, Power Place where HTML code files are placed)
Apache's default path is below HTDOCS (D: PHPENVAPACHE24HTDOCS). File index.html. This path can be modified by yourself, you can configure it in my own new folder, and configure the httpconf file to the new folder
Modified to:
DocumentRoot "D:phpEnvwww"
DirectoryIndexindex .html
为 Modified to
(5) Set the directory of the serverScript
Require All Granter
Allowoverride None
(6) Test Apache Environment Run, enter CMD, and open the command prompt. Then enter the D:phpEnvApache24bin directory and press Enter httpd and press Enter
Access the index.html file in the DocumentRoot Apache folder. If "it works" appears, the service is installed and started correctly. In (6) Configure the Windows service. The new command window enters the Apache24bin directory and knocks into the code line: httpd.exe -k install -n "servicene". ServiceName means that the service name is modified by itself, such as "Apache24".
2. PHP5.6 installation
1. Copy the php.ini-development file in the directory and rename it to php.ini. It is the configuration file of php
2. Add php support to the Apache service "
AddType application/x-httpd -php .php .phtml
3. Restart the service
(2) MySQL database support: extension_dir = "EXT", remove the previous ";" And change extension_dir = "D:phpEnvphpext" to turn on PHP extension support (the ext folder contains files that support many PHP extensions).
Remove the ";" dll
can support the mysql database by restarting the service.