我有這個聯控規則奇怪的現象:EDITED
RewriteRule ^(.*)$ $1.php [NC]// the problem is caused by this. How can I keep it without having this result?
RewriteRule ^user/(.*)$ user.php?user=$1 [NC]
RewriteRule ^ride/(.+)/$ ride.php?myRideId=$1 [NC,L]
當我這樣做:
www.example.com/ride/123
一切正常,我的瀏覽器中正確顯示但如果我嘗試使用:
$rideId = $_GET['myRideId'];
echo $rideId;
結果是:
123.php/123
我不明白爲什麼。重寫規則中有任何錯誤?
print_r($ _ GET);給你結果? –
@MihirChhatre陣列([myRideId] => 123.php/123) – mat