Successfully reported this slideshow.
We use your LinkedIn profile and activity data to personalize ads and to show you more relevant ads. You can change your ad preferences anytime.

Output cacheattribute

98 views

Published on

  • Be the first to comment

  • Be the first to like this

Output cacheattribute

  1. 1. OutputCacheAttribute By Jax
  2. 2. Properties • string CacheProfile  • int Duration  • bool NoStore   • string SqlDependency  • string VaryByContentEncoding // Accept-Encoding  • string VaryByCustom // override GetVaryByCustomString in Global.asax.cs  • string VaryByHeader // User-Agent Accept-Charset Accept-Language  • string VaryByParam • OutputCacheLocation Location    
  3. 3. Using [OutputCache(Duration = 3600, VaryByParam = "culture")]  public ActionResult Index(string culture = "zh-TW")  { 

×