Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
に新しいサイトをアップロードしましたwww.mydomain.com。古いサイトには への即時リダイレクトがありましたwww.mydomain/cart/index.php。
www.mydomain.com
www.mydomain/cart/index.php
問題は、私の新しいサイトにもカート フォルダーがあることです。/cartこのリダイレクト設定がもうないのに、ブラウザが自動的にリダイレクトしているようです。
/cart
ブラウザに、キャッシュされたリダイレクトを強制的に再キャッシュまたは更新させるにはどうすればよいですか?
URL が大きな乱数でhttp:/www.mydomain.com?a=b&c=d リダイレクトされるhttp:/www.mydomain.com?a=b&c=d&nocache=1234567890と仮定します。1234567890ブラウザはこれを新しいリクエストとして解釈する必要があります。
http:/www.mydomain.com?a=b&c=d
http:/www.mydomain.com?a=b&c=d&nocache=1234567890
1234567890
PHPを使用したソリューションはこちらです。
HTML を使用してクリアする必要がある場合
<meta http-equiv="Pragma" content="no-cache"> <meta http-equiv="no-cache"> <meta http-equiv="Expires" content="-1"> <meta http-equiv="Cache-Control" content="no-cache">
こちらを参照してください。