Apache Modify port number to modify the root directory to build multiple websites, Apache port number _php Tutorial

Source: Internet
Author: User

Apache modifies the port number to modify the root directory to build multiple websites, Apache port number


Modify Apache Port number

Select Httpd.conf under Apache, look for: Listen, you will see

#Listen 12.34.56.78:80
Listen 80
Change 80 to 90, save it.

Modify the default port for Wampserver

http://blog.csdn.net/zaocha321/article/details/7627110

Modify the Apache Web site root directory

HTTP://XMEIX.BLOG.163.COM/BLOG/STATIC/321028522012102955141433/original aim, locate the Apache directory, modify the httpd.conf file under Conf,
1 • Modify the DocumentRoot:
DocumentRoot "F:/web/www"
2 · Search (this should is changed to whatever you set DocumentRoot to) and find its next 2 lines of
Directory instead:


Restart Apache Build Multiple Sites
Open http.conf
1,servername 127.0.0.1 modified to ServerName you server IP
2, #NameVirtualHost * modified to "namevirtualhost Your server IP"
3, on the last side of the file has a virtual host format,
#
# ServerAdmin [Email]admin@minidx.com[/email]
# documentroot/www/httpd/html/minidx.com
# ServerName Minidx.com
# errorlog Logs/minidx.com-error_log
# Customlog Logs/minidx.com-access_log Common
#
Add to:

DocumentRoot usr/local/www/(Default Web site path)
ServerName Your server IP


DocumentRoot usr/local/www/minidx.com/(website path)
ServerName minidx.com (your domain)


DocumentRoot usr/local/www/ntt.cc/(website path)
ServerName ntt.cc (Your second domain)


http://blog.csdn.net/wxh0417/article/details/6152649
Http://jingyan.baidu.com/article/363872ecec3e496e4ba16fdc.html
Http://blog.sina.com.cn/s/blog_6f6b4c3c0100nei5.html

How to change the default Web port for Apache

1. Locate the httpd.conf file (i.e. d:\Apache\conf\httpd.conf) under the Conf directory in the Apache installation directory. Open it.
2. Find "Listen80", followed by Listen number is the port number, we changed to "Listen 8080". Change to a different unused port number is also OK.
3. Restart Apache for the new configuration to take effect. You can use Apache Serive Monitor in the lower right corner of the status bar to launch Apache.
You can also click Start > Run > enter cmd> carriage return > Navigate to the Apache installation directory to the bin directory, and then enter
"Httpd–k start".

How to change the Apache Web site root directory

Open the file with a text editing tool. Find DocumentRoot There is such a line Documentrootc:/program Files/apache Group/apache2/htdocs This is the root directory of your site, you can modify, you can also use the default. If you change it, change the following , or you may see a 403 error lookup?????? This should is changed to whatever the set DocumentRoot to the following two lines there

http://www.bkjia.com/PHPjc/873177.html www.bkjia.com true http://www.bkjia.com/PHPjc/873177.html techarticle Apache Modify port number to modify the root directory to build multiple websites, Apache port number modified Apache port number select Apache under Httpd.conf, look for: Listen, you will see #Listen 12.34.56.78: ...

  • Related Article

    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.