301 Redirection with htaccess and cache: How do I delete the old cache?

So, after a lot of help and research, I FINALLY was able to get 301 redirects working through the .htaccess file, but I noticed that if I really didn’t click “refresh” in my browser, it would not redirect the page due to a simple reading of the cached site.

I tried to close all browsers by inserting the .htaccess and THEN file, opening a new browser, but it still opens the cached site. I would jeopardize that most customers will not worry about refreshing the page, and if that does not happen, it will take quite a while to find out that there really is a new page!

Any ideas? Thanks!

-Charles

EDIT: I just got the idea to post a link on our current homepage, which says: "Click here to see our new site!" and the link will refresh the page, which in turn will cause 301 redirects to action. Can anyone think of any negative side effects of this?

+5
source share
2 answers

Charles,

The best way to find caching headers is to include firefox in HTML HTTP .

Here's what he says about your homepage:

HTTP/1.x 200 OK
Date: Fri, 06 Nov 2009 15:16:57 GMT
Server: Apache
Last-Modified: Mon, 12 Oct 2009 16:52:05 GMT
Etag: "85dcc1-1386-4ad35eb5"
Accept-Ranges: bytes
Content-Length: 4998
Keep-Alive: timeout=10, max=99
Connection: Keep-Alive
Content-Type: text/html

As mentioned above, the floor problem. A quick (unixy) fix could be:, find /var/www/htdocs -type f|xargs touchwhich will change the modification time of each file in your www directory.

, apache etag. Apache.

, , . , , , etags, .

Dan

+2

. , -.

, , . . :

?

0

All Articles