1.配置本地host文件:

apache 给网站配置域名

2.配置httpd-vhosts.conf 文件:

apache 给网站配置域名

3.配置httpd.conf文件:

打开 Apache 的 httpd.conf 文件(如:D:\wamp\bin\apache\apache2.4.9\conf), 添加如下代码:
# Virtual hosts
Include conf/extra/httpd-vhosts.conf
如果已存在,将Include前面的#去掉;

apache 给网站配置域名

4.重启apache服务

测试:

apache 给网站配置域名

 

相关文章:

  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-12-12
  • 2022-12-23
  • 2022-03-11
  • 2021-06-22
  • 2021-06-25
猜你喜欢
  • 2021-06-30
  • 2022-12-23
  • 2021-07-16
  • 2022-12-23
  • 2021-12-01
  • 2021-05-20
  • 2022-12-23
相关资源
相似解决方案