[英].htaccess Rewrite mod not working
我正在嘗試獲取htaccess文件以使用此文件:
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</IfModule>
重寫此URL:
http://cheesecakebb.org/index.php?action=vn
嘗試以下方法:
RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^index/([^/]+)/?$ index.php?action=$1 [QSA,L]
當有人單擊example.com/index/something
,它將重定向(無形地重定向到用戶)到index.php?action=something
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.