PHP配置环境中如何开启伪静态

1、在httpd.conf中引入httpd-vhosts.conf

2、在httpd.conf中开启mod_rewrite.so

3、在httpd-vhosts.conf中配置虚拟主机

 

 AllowOverride All 的作用:

                     AllowOverride All主要是为了实现URL重写,这点在TP5中非常重要,可以在.htaccess中进行配置,从而省略路径中的index.PHP

原文地址:https://www.cnblogs.com/mrszhou/p/7421154.html