配置门户网站

http://127.0.0.1:8080/myitcast/index.html

http://www.163.com

  1. 配置默认首页

配置网站中的web.xml文件如下

<welcome-file-list>

        <welcome-file>email.html</welcome-file>

</welcome-file-list>

  1. 配置默认网站

配置服务器的server.xml

   <Context path="" docBase="c:\sina\news"/>

  1. 配置默认端口

配置服务器的server.xml

     <Connector port="80" protocol="HTTP/1.1"

               connectionTimeout="20000"

               redirectPort="8443" />

  1. 注册域名

找到本地磁盘映射localhost主机名的配置文件。

C:\windows\system32\drivers\etc\hosts.ics配置如下

127.0.0.1 www.sina.com.cn

5. 运行结果www.sina.com.cn成功

  

相关文章:

  • 2021-12-05
  • 2021-12-26
  • 2021-12-06
  • 2021-10-28
  • 2021-11-17
  • 2021-04-30
  • 2022-12-23
  • 2022-12-23
猜你喜欢
  • 2022-12-23
  • 2022-03-09
  • 2021-12-20
  • 2021-08-12
  • 2022-12-23
  • 2021-12-18
相关资源
相似解决方案