Find your Apache installation directory, find the httpd.conf file,
Search #listen This sentence, add below
Copy Code code as follows:
Listen 800
Listen 801
Listen 802
Here is the test, you can according to your need to add different listening port, OK, the Apache web port is open, we have to configure the virtual host.
Found it
Copy Code code as follows:
#<virtualhost *:80>
# serveradmin Webmaster@dummy-host2.phps Tutorial hao.cublog.cn
# Documentroot/www/docs/dummy-host2.phps Tutorial hao.cublog.cn
# servername dummy-host2.phpshao.cublog.cn
# errorlog Logs/dummy-host2.phpshao.cublog.cn-error_log
# Customlog Logs/dummy-host2.phpshao.cublog.cn-access_log Common
#</virtualhost>
Type this code, because the installation directory is different, there will be a small difference, we directly search <virtualhost *:80> also line, and then add the following
Copy Code code as follows:
<virtualhost 192.168.0.110:802>//802 is our increased listening web port
ServerAdmin qq@sina.com
DocumentRoot d:/www/www.php100.com/
ServerName www.php100.com
Errorlog Logs/dummy-host2.phpshao.cublog.cn-error_log
Customlog Logs/dummy-host2.phpshao.cublog.cn-access_log Common
</virtualhost>
The last step is to get Apache back on the OK