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

2026-02-20 21:30:56

1、编辑httpd配置文件

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

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、如果以上经验帮到您,麻烦在左下角给点个赞,谢谢!

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

猜你喜欢