[b]http://msdn.microsoft.com/en-us/library/bb250442(VS.85).aspx[/b]
Table 1. Client Cache Headers
[table]
|Pragma: no-cache|The client is unwilling to accept any cached responses from caches along the route and the origin server must be contacted for a fresh copy of the resource.
|If-Modified-Since|datetime The server should return the requested resource only if the resource has been modified since the date-time provided by the client.
|If-None-Match: etagvalue|The server should return the requested resource if the ETAG of the resource is different than the value provided by the client. An ETAG is a unique identifier representing a particular version of a file.
[/table]
[b]Any Cache-Control directives supersede the Expires header.[/b]
Table 2. Common Cache-Control Headers
[table]
|public|The response may be stored in any cache, including caches shared among many users.
|private|The response may only be stored in a private cache used by a single user.
|no-cache|The response should not be reused to satisfy future requests.
|no-store|The response should not be reused to satisfy future requests, and should not be written to disk. This is primarily used as a security measure for sensitive responses.
|max-age=#seconds|The response may be reused to satisfy future requests within a certain number of seconds.
|must-revalidate|The response may be reused to satisfy future requests, but the origin server should first be contacted to verify that the response is still fresh.
[/table]
[list]
[*]1)For legacy reasons, servers may send a Pragma: no-cache header. This is treated as Cache-Control: no-cache.
[*]2)The Vary header signals to a cache that a response is valid for reuse only under certain circumstances. For example, use Vary: User-Agent to direct that the current response may only be reused for future requests sending the same User-Agent header. The directive Vary: * is equivalent to Cache-Control: no-cache.
[*]3)关于Vary的定义:http://www.w3.org/Protocols/rfc2616/rfc2616-sec14.html#sec14.44
[/list]
Table 1. Client Cache Headers
[table]
|Pragma: no-cache|The client is unwilling to accept any cached responses from caches along the route and the origin server must be contacted for a fresh copy of the resource.
|If-Modified-Since|datetime The server should return the requested resource only if the resource has been modified since the date-time provided by the client.
|If-None-Match: etagvalue|The server should return the requested resource if the ETAG of the resource is different than the value provided by the client. An ETAG is a unique identifier representing a particular version of a file.
[/table]
[b]Any Cache-Control directives supersede the Expires header.[/b]
Table 2. Common Cache-Control Headers
[table]
|public|The response may be stored in any cache, including caches shared among many users.
|private|The response may only be stored in a private cache used by a single user.
|no-cache|The response should not be reused to satisfy future requests.
|no-store|The response should not be reused to satisfy future requests, and should not be written to disk. This is primarily used as a security measure for sensitive responses.
|max-age=#seconds|The response may be reused to satisfy future requests within a certain number of seconds.
|must-revalidate|The response may be reused to satisfy future requests, but the origin server should first be contacted to verify that the response is still fresh.
[/table]
[list]
[*]1)For legacy reasons, servers may send a Pragma: no-cache header. This is treated as Cache-Control: no-cache.
[*]2)The Vary header signals to a cache that a response is valid for reuse only under certain circumstances. For example, use Vary: User-Agent to direct that the current response may only be reused for future requests sending the same User-Agent header. The directive Vary: * is equivalent to Cache-Control: no-cache.
[*]3)关于Vary的定义:http://www.w3.org/Protocols/rfc2616/rfc2616-sec14.html#sec14.44
[/list]