PHP Build Environment process

Source: Internet
Author: User

1, first build apache2.4

: https://www.apachelounge.com/download/;

Download the. zip file and extract it to ' d:\wamp\ ', the following are installed in this directory; renamed to Apache24, edit d:\wamp\www by d:\wamp\apache24\ The DocumentRoot and directory options in httpd.conf in the Conf directory are d:/wamp/apache24;

Then configure Apache to access directory d:\wamp\www externally, by modifying the content in the httpd.conf

DocumentRoot ""
<directory "" >

For

DocumentRoot "D:/wamp/www"
<directory "D:/wamp/www" >

Then under the cmd command, enter into the bin directory of Apache24, enter the command httpd-k install; Install, then start the command httpd-k start, enter 127.0.0.1 in the browser to verify, if it works! is normal

2, install PHP

: Http://windows.php.net/download;

Download the. zip file and extract it to ' D:\wamp\ '; renamed to php7.0,

Then copy the php.ini-production under d:\wamp\php7.0 and rename it to PHP.ini, (open the php.ini file in Notepad, change the extension library path Extension_dir = "d:/wamp/php7.0/ Ext ", note not the backslash);

In the d:\wamp\apache24\conf directory, open httpd.conf and add the following statement

LoadModule php7_module "D:\wamp\php7.0\php7apache2_4.dll"
Phpinidir "d:\wamp\php7.0"
AddType application/x-httpd-php. php

(Note that this is a backslash);

Restart the Apache24 service, under the cmd command, enter net stop apache2.4 carriage return net start apache2.4 Enter,(if error, it is possible not to open the cmd command as an administrator, or the service name case, or the environment variable is not configured) ;

Build index.php under D:\wamp\www (<?php phpinfo ();) In the last browser open 127.0.0.1, enter will appear php details.

3, install MySQL

: http://dev.mysql.com/downloads/mysql/;

Download the. zip file and extract it to ' D:\wamp\ '; renamed to mysql5.7;

Copy the My-default.ini, and rename it to My.ini (or directly create My.ini), which reads as follows:

Edit the My.ini, configured as follows:
[MySQL]
Default-character-set=utf8
[Mysqld]
# Remove Leading # and set to the amount of RAM for the most important data
# Cache in MySQL. Start at 70% of all RAM for dedicated server, else 10%.
# innodb_buffer_pool_size = 128M
# Remove Leading # to turn on a very important data integrity option:logging
# Changes to the binary log between backups.
# Log_bin
# These is commonly set, remove the # and set as required.
Basedir = d:\wamp\mysql5.7
DataDir = D:\wamp\mysql5.7\data
Port = 3306
Max_connections = 200
Character-set-server = UTF8
Default-storage-engine = INNODB

Then start the cmd command, switch to the D:\wamp\mysql5.7\bin directory, enter the command mysqld--install, and then enter

Mysqld--initalize-insecure--user=mysql

After executing the above command, MySQL automatically creates the data folder, and the default database is built, the login user name is root, the password is empty, and the last input net start MySQL starts MySQL service.

(Authentication method: Enter mysql-uroot-p in the cmd command and return, encounter the password direct carriage return, "mysql>" is successful)

Note:

Under 64-bit operating systems and 32-bit operating systems, 64-bit software names are 64, while 32-bit software is with x86, and there are different versions of VCs that need to be configured

PHP Build Environment process

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.