Configure HTTP service in Windows (Windows + Apache + Mysql + PHP) and apachemysql

Source: Internet
Author: User

Configure HTTP service in Windows (Windows + Apache + Mysql + PHP) and apachemysql
1. Install WampServer2. manage HTTP Services

Task iconGreen indicates normal startStatus

Note:
1. Check whether the network can ping the IP address of the other party.
2. Check whether the firewall is enabled. If enabled, the firewall cannot be accessed normally.
3. Check Access PermissionsAllow from all
4. Make sure the port is notOther programsOccupied

3. Configure the root directory:

The website root directory is the space for storing website programs on the Web server.

3.1 open the configuration file and select the console or bin \ apache \ Apache2.2.21 \ conf \ httpd. conf in the wampserver installation directory.

3.2 set the root directory, find and modify

Can be modified

In this way, the root directory for storing the website is specified.

3.3 configure the root directory

Can be modified

3.4 after modification, it cannot take effect immediately.Restart Apache

4. Website deployment

Paste the webpage we createdCopyGo to the configured root directory and access 127.0.0.1 through the browser.

5. Configure the VM

On a Web server, we can configure the virtual host and set the root directory separately to manage multiple websites.

5.1 enable the auxiliary configuration of the VM and find it in httpd. conf.

Remove the # Note and enable the VM configuration.

5.2 configure the VM to open conf/extra/httpd-vhosts.conf

Modify the following three items:

DocumentRoot "E:/www/example"
ServerName "example.com"
ServerAlias "www.example.com"

5.3 modify the DNS (hosts) file to open the C: \ Windows \ System32 \ drivers \ etc \ hosts Directory, which is fixed.

Note: Modify the hosts File Permission

 

6. Restart the Apache browser to access www.example.com.

 

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.