SlideShare ist ein Scribd-Unternehmen logo
1 von 3
OutputCacheAttribute
By Jax
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    
Using
[OutputCache(Duration = 3600, VaryByParam = "culture")] 
public ActionResult Index(string culture = "zh-TW") 
{ 

Weitere ähnliche Inhalte

Andere mochten auch

Design pattern proxy介紹 20130805
Design pattern proxy介紹 20130805Design pattern proxy介紹 20130805
Design pattern proxy介紹 20130805LearningTech
 
Powershell function
Powershell functionPowershell function
Powershell functionLearningTech
 
Will c# programming guild
Will c# programming guildWill c# programming guild
Will c# programming guildLearningTech
 
Bacias Hidrográficas - Parte II
Bacias Hidrográficas - Parte IIBacias Hidrográficas - Parte II
Bacias Hidrográficas - Parte IILCGRH UFC
 
Download-manuals-gis-gis methodology-manual
 Download-manuals-gis-gis methodology-manual Download-manuals-gis-gis methodology-manual
Download-manuals-gis-gis methodology-manualhydrologywebsite1
 

Andere mochten auch (7)

Design pattern proxy介紹 20130805
Design pattern proxy介紹 20130805Design pattern proxy介紹 20130805
Design pattern proxy介紹 20130805
 
Powershell function
Powershell functionPowershell function
Powershell function
 
Power shell
Power shellPower shell
Power shell
 
Will c# programming guild
Will c# programming guildWill c# programming guild
Will c# programming guild
 
Geoloaction
GeoloactionGeoloaction
Geoloaction
 
Bacias Hidrográficas - Parte II
Bacias Hidrográficas - Parte IIBacias Hidrográficas - Parte II
Bacias Hidrográficas - Parte II
 
Download-manuals-gis-gis methodology-manual
 Download-manuals-gis-gis methodology-manual Download-manuals-gis-gis methodology-manual
Download-manuals-gis-gis methodology-manual
 

Mehr von LearningTech

Mehr von LearningTech (20)

vim
vimvim
vim
 
PostCss
PostCssPostCss
PostCss
 
ReactJs
ReactJsReactJs
ReactJs
 
Docker
DockerDocker
Docker
 
Semantic ui
Semantic uiSemantic ui
Semantic ui
 
node.js errors
node.js errorsnode.js errors
node.js errors
 
Process control nodejs
Process control nodejsProcess control nodejs
Process control nodejs
 
Expression tree
Expression treeExpression tree
Expression tree
 
SQL 效能調校
SQL 效能調校SQL 效能調校
SQL 效能調校
 
flexbox report
flexbox reportflexbox report
flexbox report
 
Vic weekly learning_20160504
Vic weekly learning_20160504Vic weekly learning_20160504
Vic weekly learning_20160504
 
Reflection & activator
Reflection & activatorReflection & activator
Reflection & activator
 
Peggy markdown
Peggy markdownPeggy markdown
Peggy markdown
 
Node child process
Node child processNode child process
Node child process
 
20160415ken.lee
20160415ken.lee20160415ken.lee
20160415ken.lee
 
Peggy elasticsearch應用
Peggy elasticsearch應用Peggy elasticsearch應用
Peggy elasticsearch應用
 
Expression tree
Expression treeExpression tree
Expression tree
 
Vic weekly learning_20160325
Vic weekly learning_20160325Vic weekly learning_20160325
Vic weekly learning_20160325
 
D3js learning tips
D3js learning tipsD3js learning tips
D3js learning tips
 
git command
git commandgit command
git command
 

Output cacheattribute