0
我想將不存在的整個文件夾重定向到主頁。htaccess重定向一個不再存在的文件夾
我嘗試:
RedirectMatch 301 ^/folder_thats_no_longer_exists/$/
RedirectMatch 301 ^/folder_thats_no_longer_exists/
RedirectMatch 301 /folder_thats_no_longer_exists/
但這種解決方案不起作用:
事實上,這種嘗試後,該網址仍是:http://www.example.com/folder_thats_no_longer_exists/page.htm但隨着網頁的內容(這是導致顯示錯誤)。
我只是想: http://www.example.com/folder_thats_no_longer_exists/page.htm去到http://www.example.com/ 301重定向。
謝謝!