Linux中使用Apache发布html网页


  • 在线学习:
  • https://www.shiyanlou.com/courses/1
  • 工具/原料

  • Linux,httpd,vi
  • 样例html文件一份

方法/步骤

 
  1. 1

    编辑httpd配置文件

    Linux中使用Apache发布html网页(下)
  2. 2

    查找DirectoryIndex配置段

    Linux中使用Apache发布html网页(下)
  3.  

    在这后面添加index2.html也就是刚才的网页名称

    Linux中使用Apache发布html网页(下)
  4.  

    在这把监听端口改为了8080

    Linux中使用Apache发布html网页(下)
  5.  

    保存并退出

    Linux中使用Apache发布html网页(下)
  6.  

    重启httpd服务

    Linux中使用Apache发布html网页(下)
  7.  

    浏览测试,说明配置成功

    Linux中使用Apache发布html网页(下)
  8.  

    这里可以修改字体是否支持中文

    Linux中使用Apache发布html网页(下)
  9.  

    这里是网页的存放路径

    Linux中使用Apache发布html网页(下)
  10.  

    这里是网页的存放目录要与16步骤中的最好一致

    Linux中使用Apache发布html网页(下)
  11.  

    如果字体中的中文显示乱码,可以修改这里,请参考该图片

    Linux中使用Apache发布html网页(下)
  12.  赞


免责声明!

本站转载的文章为个人学习借鉴使用,本站对版权不负任何法律责任。如果侵犯了您的隐私权益,请联系本站邮箱yoyou2525@163.com删除。



 
粤ICP备18138465号  © 2018-2025 CODEPRJ.COM