我想重寫規則,重寫這個很長的網址,以搜索引擎優化友好的一個。 但是,我的規則不起作用,目標網址變成404頁面。 我會很感激任何幫助。謝謝!如何使正確的mod_rewrite規則在.htaccess
這是原始URL的一個例子
http://www.mydomain.com/index.php?module=product&pId=102&id=14495&category=computer/DELL&start=0/
這是我的重寫規則
重寫規則^模塊/([^ /] )/ PID /([^ /])/ id /([^ /] )/ category /([^ /])/ start /([^ /] *)$ /index.php?module=$1 & pId = $ 2 & id = $ 3 &類別= $ 4 &開始= $ 5 L]
這是轉換後的網址
http://www.mydomain.com/index/module/product/pId/102/id/14495/category/computer/DELL/start/0/
'([^ /])' - 這是什麼意思? – zerkms