ThinkPHP5.0 apache服务器配置URL重写,index.php去除

发布时间 2023-12-17 10:01:43作者: 小林不会飞

本地环境wamp

 .htaccess文件代码

<IfModule mod_rewrite.c>
    Options +FollowSymlinks -Multiviews
    RewriteEngine on
    
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteRule ^(.*)$ index.php?/$1 [QSA,PT,L]
</IfModule>