I want an auto hard refresh, not a simple auto refresh on my webpages

余生长醉 提交于 2019-12-04 08:04:43

I was searching for an answer to this, and it's all in the headers apparently.

You need to send a no-cache header, in php this would be:

header("Cache-Control: no-cache, must-revalidate"); // HTTP/1.1
header("Expires: Sat, 26 Jul 1997 05:00:00 GMT"); // Date in the past

..and then just refresh as normal (javascript or meta).

Use this Method:

http://grizzlyweb.com/webmaster/javascripts/refresh.asp

It uses JS to the refresh and won't load the page from the browsers bf-cache so it should do what you require. It will also prevent entries from going into the users BF-cache so they will be able to use the back button correctly.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!