How to configure virtual host in Apache server

    Read

How to set up multiple websites and bind different directories in the Apache server?

In fact, it is very simple to find httpd.conf in the server. This is the configuration file of Apache. SourceByrd's Weblog- https://note.t4x.org/basic/apache-config-virtualhost/

Assume that my domain name is www.selmy.org, and my bound directory is/var/www/docs/selmys/ SourceByrd's Weblog- https://note.t4x.org/basic/apache-config-virtualhost/

Find: httpd.conf

SourceByrd's Weblog- https://note.t4x.org/basic/apache-config-virtualhost/

Then edit httpd.conf and add the following:


My other website is assumed to be www.baidu.com SourceByrd's Weblog- https://note.t4x.org/basic/apache-config-virtualhost/

that

SourceByrd's Weblog- https://note.t4x.org/basic/apache-config-virtualhost/

Statement: Reprinted on the Internet, the copyright belongs to the original author! SourceByrd's Weblog- https://note.t4x.org/basic/apache-config-virtualhost/ SourceByrd's Weblog- https://note.t4x.org/basic/apache-config-virtualhost/

Statement: unless otherwise specified Byrd's Blog The content is original. Reproduction without permission is prohibited! For details, please read Copyright Statement !
 Byrd
  • by Published on March 10, 2014
  • Original link: https://note.t4x.org/basic/apache-config-virtualhost/
 anonymous

Comment

Anonymous

 :?:  :razz:  :sad:  :evil:  :!:  :smile:  :oops:  :grin:  :eek:  :shock:  :???:  :cool:  :lol:  :mad:  :twisted:  :roll:  :wink:  :idea:  :arrow:  :neutral:  :cry:  :mrgreen: