Jason_40769
Mar 30, 2012Nimbostratus
no-cache Irule
We are wanting to force caching and set the maxage via an irule except on a certain link. We tried this rule but it doesnt seem to work ALL the time. Thoughts?
when HTTP_REQUEST {
DEFAULT cache value for all pages
set cache_value "public, max-age=300"
center should not be cached
if { [HTTP::uri] contains "/center" } {
set cache_value "private, no-cache"
}
}
when HTTP_RESPONSE {
HTTP::header replace Cache-control $cache_value
}