1
我有htaccess重寫mods使用虛榮URL。我試圖手動將一個$ _GET變量傳遞給一個登錄頁面,告訴人們登錄失敗,但由於vanity URL,手動傳遞的$ _GET變量被忽略。我該如何解決?
這裏就是我試圖通過,
http://mysite.com/login?failed=1
但爲它工作的唯一方法是做到以下幾點,
http://mysite.com/?p=login&failed=1
它創建一個明顯的醜陋的效果。
我htaccess文件,
RewriteEngine On
RewriteBase /ncms/admin
RewriteRule ^([a-zA-Z0-9-]+)$ index.php?p=$1 [L]
RewriteRule ^([a-zA-Z0-9-]+)/$ index.php?p=$1 [L]