0
我試圖通過使用下面的設置配置Apache webserver httpd.conf來將所有index.html重定向到根文件夾。它能夠成功重定向,但它始終指向testsite.com //而不是testsite.com/。任何想法爲什麼它保持轉發到URL與2斜線'/'?感謝您的建議,謝謝!使用httpd.conf將index.html重定向到根目錄
RewriteEngine On
RewriteRule ^index\.html$/[R=301,L]
RewriteRule ^(.*)/index\.html$ $1 [R=301,L]
任何人都可以幫助嗎?謝謝。 – Ryan
沒有人知道爲什麼? – Ryan