继续我在这里问的内容,我想自动重写以下网址
http://testsite.com/siterootb/sample-page.php?bbi=value1&bbl=value2
至
http://testsite.com/siterootb/sample-page/value1/value2
我htaccess
现在看起来像
RewriteEngine on
RewriteCond %{QUERY_STRING} !^$
RewriteRule ^(.*) http://localhost%{REQUEST_URI}%1? [R=301,L]
###########################################################################
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_URI} ^/siterootb/([^/]+)/([^/]+)/([^/]+)
RewriteCond %{DOCUMENT_ROOT}/siterootb/%1.php -f
RewriteRule ^/?([^/]+)/([^/]+)/([^/]+) $1.php?bbi=$2&bbl=$3 [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME}.php -f
RewriteRule ^(.*)$ $1.php [L]
我经历了URL重写-查询字符串,url重写查询字符串,wordpress如何删除?从使用 htaccess 的 url和更多我得到的[query-string] [.htaccess]