EXPIRES:
Example:
< META HTTP-EQUIV="EXPIRES" CONTENT="Mon, 22 Jul 2002 11:12:01 GMT" >
response.setDateHeader("Expires", 0);
The following example sets expiration for 15 seconds
long now = System.currentTimeMillis();
response.setDateHeader("Expires", now + 15000);
Description:
The date and time after which the document should be considered expired. An illegal EXPIRES date, e.g. "0", is interpreted as "now". Setting EXPIRES to 0 may thus be used to force a modification check at each visit.
Web robots may delete expired documents from a search engine, or schedule a revisit.
PRAGMA:
Example:
< META HTTP-EQUIV="PRAGMA" CONTENT="NO-CACHE" >
response.setHeader("Pragma", "No-cache");
Description:
This directive indicates cached information should not be used and instead requests should be forwarded to the origin server. This directive has the same semantics as the CACHE-CONTROL:NO-CACHE directive and is provided for backwards compatibility with HTTP/1.0.
Clients SHOULD include both PRAGMA:NO-CACHE and CACHE-CONTROL:NO-CACHE when a no-cache request is sent to a server not known to be HTTP/1.1 compliant.
CACHE-CONTROL:
Example:
< META HTTP-EQUIV="CACHE-CONTROL" CONTENT="NO-CACHE" >
response.setHeader("Cache-Control", "no-store, no-cache, must-revalidate");
Description:
The directive CACHE-CONTROL:NO-CACHE indicates cached information should not be used and instead requests should be forwarded to the origin server. This directive has the same semantics as the PRAGMA:NO-CACHE.
Clients SHOULD include both PRAGMA:NO-CACHE and CACHE-CONTROL:NO-CACHE when a no-cache request is sent to a server not known to be HTTP/1.1 compliant.
REFRESH:
Example:
< META HTTP-EQUIV="REFRESH"
CONTENT="15;URL=http://www.I18nGuy.com/index.html" >
It keeps on refreshing the page at frequent intervals
Description:
Specifies a delay in seconds before the browser automatically reloads the document. Optionally, specifies an alternative URL to load, making this command useful for redirecting browsers to other pages.
Further reference: Click here
No comments:
Post a Comment