我的 .htaccess 文件中有这个:
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /test/
RewriteCond %{REQUEST_URI} !(panel/index.php)
RewriteRule ^panel/(.*)$ panel/index.php/$1/ [L]
</IfModule>
我想隧道所有包含panel/(.*)
to的链接来panel/index.php
控制它们。
上述规则有效,除非 url 是http://localhost/test/panel/
! 它重定向到:
http://localhost/test/panel/index.php/index.php/index.php/index.php/index.php/index.php/index.php/index.php/index.php/index.php/index.php/index.php/index.php/index.php/index.php/index.php/index.php/index.php/index.php/index.php/index.php/
需要帮助。