1)我得到了mysite.com/about-me.php。
.htaccess&301:將大寫字母重定向到相同的URL,但小寫
當我輸入mysite.com/About-me.php時,出現404錯誤。
我想爲我的.htaccess添加一些魔力,以便mysite.com/My-PaGe.php (etc) redirects the user by 301, OR rewrites the URL (whatever is the best?) to mysite.com/my-page.php.
- 是301還是重寫最好?
2)是否可能爲我添加一個適用於所有URL的規則,還是我必須手動指定所有不同的頁面?
獎金3)額外獎金星級,如果有人知道如何改寫mysite.com/mY-paGe.php到mysite.com/my-site
非常感謝
@duncan ..和?如果你沒有RewriteMap聲明,它應該如何工作?這個規則本身沒有任何用處。 – LazyOne
好點,我忘了地圖。更新我的答案以包含它。 – duncan
@duncan那麼..問題仍然是「種」仍然 - RewriteMap **不能**在.htaccess中聲明。至少要記下這個不幸的時刻(如果能像那樣工作,那會更容易)。 – LazyOne