Created
April 4, 2014 09:41
-
-
Save contensis/9971338 to your computer and use it in GitHub Desktop.
Custom Cache
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
' This example will hardcode a cache on every oage that uses a particular template | |
Response.Cache.SetCacheability(Web.HttpCacheability.Public) | |
Response.Cache.SetExpires(Now.AddSeconds(60)) | |
Response.Cache.SetValidUntilExpires(True) | |
'We want all Querystring parameters to be cached individually. | |
Response.Cache.VaryByParams("*") = True | |
Response.Cache.SetVaryByCustom("browser") |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment