0
我的URL:mod_rewrite的三個參數
localhost/categories?DPt=MQ==&CTg=MQ==&NLs=Mw==
我想這樣:
localhost/product-a/departure-a/categories-a/
我的htaccess:
<IfModule mod_rewrite.c>
RewriteRule ^confirmation/?$ confirmation.php [NC,L]
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^/?([^/]+)/?$ products.php?PDt2=$1 [QSA,NC,L]
RewriteRule ^/?categories/([^/]+)/?$ categories.php?DPt=$1&CTg=$2&NLs=$3 [QSA,NC,L]
</IfModule>
但事實並非如此。 有什麼不對?
這些規則似乎確實不匹配您正在嘗試做任何事情。什麼是真正的URL,你想讓它看起來像在瀏覽器中? –
products-b/departure-b/categories-b/ – dev20152015
這沒有幫助。它應該改寫成什麼?帶參數的真實網址。 –