要約すると、現在、htaccess ファイルに問題があります。301 リダイレクトは、新しく記述された URL を通過しますが、さらに、新しい URL の後に ? が続きます。そして旧URL。どうすれば を取り除くことができますか? と以前の URL を組み合わせて、エンディングとして表示されないようにします。
この問題に関してオンラインで見つけた例はどれも機能していないようです。誰かアドバイスをお願いできますか?RewriteRule を使用してこれを停止できますか?
htaccessファイルの概要は次のとおりです
# begin redirects
# There are redirects of a number of old pages. Here's a sample of them.
redirect 301 /index.html http://www.petersommer.com/
redirect 301 /escorted-archaeological-tours/turkey/western-lycia-cruise-july/ http://www.petersommer.com/escorted-archaeological-tours/
RewriteRule ^gallery/main.php$ http://www.petersommer.com/gallery/ [R=301,L]
RewriteRule ^pdf/how_to_book.pdf$ http://www.petersommer.com/pdf/how-to-book-holiday.pdf [R=301,L]
# end redirects
<IfModule mod_rewrite.c>
RewriteEngine On
Options +FollowSymLinks
DirectoryIndex index.php
RewriteEngine On
RewriteCond $1 !^(images|system|themes|pdf|favicon\.ico|robots\.txt|index\.php) [NC]
RewriteRule ^\.htaccess$ - [F]
RewriteRule ^favicon\.ico - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ /index.php?/$1 [L]
</IfModule>
DirectoryIndex index.php
残念ながら、何が機能していないのか、それを修正するために何をする必要があるのか わかりません。書き換えルールに何かあるに違いないか、修正するためにいくつかの書き換えルールを追加する必要があると思います。
残念ながら、すべてのリダイレクトで ? が追加されています。古い URL を新しいリダイレクトされた URL の末尾に追加します。たとえば、次のようになります。
toのリダイレクト 301 は
、単にではなく/tours2006.html
to
/escorted-archaeological-tours/
を通過します。/escorted-archaeological-tours/?/tours2006.html
/escorted-archaeological-tours/
残念ながら、すべてが同じパターンに従っています。
書き換えルールに不具合が見られる場合、または追加する必要があるものを特定できる場合は、非常に感謝しています。