我的.htaccess文件正常工作與以下網址PHP友好的URL的.htaccess - 搜索頁面
http://www.mywebsite.com/product/category/Girls-Clothes
.htaccess文件:
RewriteEngine On
RewriteRule ^product/category/([a-zA-Z0-9-/]+)$ /product/category/category.php?cid=$1
RewriteRule ^product/category/([a-zA-Z0-9-/]+)/$ /product/category/category.php?cid=$1
但是當我使用頁碼沿這將無法正常工作
http://www.mywebsite.com/product/category/Girls-Clothes?pno=2
我有兩個變量cid和pno,CID是在.htaccess中提到的,但是當我嘗試「pno」時,它給了我sql錯誤。
RewriteRule ^uk/category/([a-zA-Z0-9-/]+)$ /uk/category/category.php?cid=$1?pno=$1
RewriteRule ^uk/category/([a-zA-Z0-9-/]+)/$ /uk/category/category.php?cid=$1?pno=$1
請讓我知道我做錯了
您應該在查詢字符串參數之間使用&符('&')。喜歡:'/uk/category/category.php?cid = $ 1&pno = $ 1' – arcyqwerty 2012-07-29 00:56:46