First, the software download
httpd-2.4.12-win64-vc11.zip:http://www.apachelounge.com/download/
php-5.6.6-win32-vc11-x64.zip:http://windows.php.net/download/
Second, installation method/step
1, install Apache server;
①: Unzip the Httpd-2.4.12-win64-vc11.zip to the established directory; For example, my directory: C:\TheInstallationOfMine\apache
②: Open the apache24\conf directory, modify the httpd.conf file;
(1) Modify the root path of serverroot Apache; for example: (37 lines) ServerRoot "C:/apache24" to->serverroot "c:/theinstallationofmine/apache/ Apache24 "
(2) Modify DocumentRoot Apache access to the home folder directory, is the location of PHP, HTML code files, for example: (248 lines) documentroot "C:/apache24/htdocs" changed to DocumentRoot"C:/theinstallationofmine/apache/apache24/htdocs" (249) <directory "C:/Apache24/htdocs" > Change to-><directory "C:/theinstallationofmine/apache/apache24/htdocs" >
③: Set Serverscript directory, for example: (381) <directory "C:/apache24/cgi-bin" > Change to-><directory "c:/ Theinstallationofmine/apache/apache24/cgi-bin ">
④: To this Apache settings have been modified, you can start Apache, for example: Into the Apache24 bin directory double-click Httpd.exe can launch Apache server;
⑤: Add Apache to the window service startup entry and set it to boot; for example: Reopen a new command window into the C:/theinstallationofmine/apache/apache24/bin directory:
I added: Httpd.exe-k install-n "Apache2. 4 "The command succeeds with a successful prompt and you can see the Apache2in the Window service startup item. 4 This service
2, installation php5.6.6;
①: Extract the downloaded php-5.6.6-win32-vc11-x64.zip to the installation directory mine is (C:\TheInstallationOfMine\php5.6.6)
②: Copy the Php.ini-development file under the directory and rename it to php.ini he is a PHP configuration file
③: Add PHP support for Apache services
Open Apache configuration file http.conf at the end of the add
# PHP5 Support
LoadModule Php5_module C:/theinstallationofmine/php5.6.6/php5apache2_4.dll
AddType application/x-httpd-php. php. phtml
# Configure Thepath to PHP.ini
Phpinidir "c:/theinstallationofmine/php5.6.6"
Phpinidir "c:/theinstallationofmine/php5.6.6" This is your PHP root directory.
④: restart Apache server;
⑤: test; Create a new index.php, <?php phpinfo (),?> Save, access to the information that appears in PHP indicates that PHP has been successfully installed.
3, installation of MySQL here does not introduce, but note that at this time, PHP does not have the function of data, because the MySQL link library is not open, the way to open the following:
①: Open PHP configuration file php.ini (C:\TheInstallationOfMine\php5.6.6\php.ini)
②: (721 lines); Extension_dir = "ext", remove the front ";" and change to Extension_dir = "C:\TheInstallationOfMine\php5.6.6\ext" to open PHP extension support, Ext folder has a lot of PHP extension support. dll files, interested students can look.
③: Then it's the MySQL extension that opens PHP
875, 876 lines) remove the front ";"
Extension=php_mysql.dll
Extension=php_mysqli.dll
④: Restart Apache if not error at this time the basic installation is complete;
Win7 (64-bit) system installation apache+php