创建应用目录后入口文件index.php应如何改写

日期:2021-06-05 14:56:16 人气:1

创建应用目录后入口文件index.php应如何改写

可以通过URL重写隐藏应用的入口文件index.php
[ Apache ]
1. httpd.conf配置文件中加载了mod_rewrite.so模块
2. AllowOverride None 将None改为 All
3. 把下面的内容保存为.htaccess文件放到应用入口文件的同级目录下
<IfModule mod_rewrite.c>RewriteEngine onRewriteCond %{REQUEST_FILENAME} !-
    A+
热门评论