Graeme Posted August 10, 2012 Report Share Posted August 10, 2012 Hello All, I've been reading up on caches and I once had some code in a site that gave a fresh page every time it loaded but I can't remember how I did it! Any advice will be most appreciated, Thank you, Best wishes Graeme Quote Link to comment Share on other sites More sharing options...
grabenair Posted August 11, 2012 Report Share Posted August 11, 2012 (edited) 1- <META HTTP-EQUIV="PRAGMA" CONTENT="NO-CACHE"> This directive indicates cached information should not be used and instead requests should be forwarded to the origin server. 2- <meta http-equiv="expires" content="0"> Setting the content to "0" tells the browsers to always load the page from the web server. But you can also tell the browsers how long to leave a page in cache. Instead of "0" you write the date, including time, that you would like the page to be reloaded from the server. Note, the time should be in Greenwich Mean Time (GMT) and written in the format Day, dd Mon yyyy hh:mm:ss. Like this: <meta http-equiv="expires" content="Thu, 19 Oct 2000 00:00:00 GMT"> I got these two from a Google search I have not tried them. Edited August 11, 2012 by grabenair Quote Link to comment Share on other sites More sharing options...
Graeme Posted August 11, 2012 Author Report Share Posted August 11, 2012 Thank you for this and for explaining it so well Best wishes Graeme Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.