Win10 system to build Apache and PHP environment method

  
In today's Win10 system use tutorial, we will share with you the method of building Apache and PHP development environment under Win10 system. Some netizens may ask: The Win10 system is equipped with Apache and PHP development environment is not the same as Win7/Win8.1, Xiaobian's reply is: indeed. But if you still don't know how to build it, take a look at today's tutorial!

Win10 System
First, download the Apache and PHP that match the system digits on Microsoft's official website. Configure Apache
Apache version: Apache2.4.18
Unzip directory: D:Acpache24
1. Download the extracted file, unzip it and place it in the location to be installed.
2, open the httpd.conf file under Apache24conf, modify the following key locations, open it with Notepad.
ServerRoot modified to the location of the Apache program:
Before the modification: ServerRoot “c:/Apache24”;
Before the modification: ServerRoot “D:/Apache24”;
Modify the Apache default website Root directory:
Before modification: DocumentRoot “c:/Apache24/htdocs”;
Modified: DocumentRoot “D:/Apache24/htdocs”;
Options for modifying the root directory:
Modify前:
"Directory “c:/Apache24/htdocs”"
Options Indexes FollowSymLinks
AllowOverride null
Require all granted
"/Directory"
Modified:
"Directory “D:/Apache24/htdocs”"
Options Indexes FollowSymLinks
AllowOverride All
Require all granted
"/Directory"
Start Apache
1,“Win + R”'s chat box input “cmd”, start “ command prompt window & rdquo;.
2, input “d:” Enter, enter “cd Apache24bin” Enter, enter “httpd”, if there is no prompt, the startup is successful.
3, open the browser input “ http://localhost /& rdquo; to test, as shown below shows that the configuration is successful.
Second, install and configure PHP
PHP version: php5.6.12
Installation directory: d:php
1, download the file is unpacked, unzip it and put it in the location to be installed.
2, copy php.ini-development, and renamed php.ini.
3, open httpd.conf under Apache24conf, at the end add
#php5 support
LoadModule php5_module “D:/PHP/php5apache2_4.dll”
AddHandler application/x-httpd-php . Php
PHPIniDir “D:/php/”
4, restart the Apache server.
(Install the server: 1. Open the command prompt window as the administrator; 2. Enter “D:”, Enter; 3. Enter “cd Apache24bin”, Enter; 4. Enter “httpd. Exe -k install -n ”Apache24“”, enter, you can install successfully; 5, "Win + R"; Run "lds; services.msc", open the service window, start "ldld; Apache2.4" service; )
5. Delete other files in Apache24/htdocs, create a new index.php, and access the php information to indicate that php has been successfully installed.
The above is the step of Win10 system to build Apache and PHP environment. If you want to develop Web server software, Win10 is a good choice for development environment.

Copyright © Windows knowledge All Rights Reserved