%META:TOPICINFO{author="TWikiContributor" date="1386207954" format="1.1" version="$Rev$"}%
%META:TOPICPARENT{name="TWikiVariables"}%
#VarVARCACHE
---+++ VARCACHE{ _attributes_ } -- cache TWiki variables in selected topics for faster page rendering
   * The =%<nop>VARCACHE{}%= variable is handled by the VarCachePlugin. 
   * Syntax: =%<nop>VARCACHE{ "24" }%=
   * Supported attributes:
     | *Attribute* | *Comment* | *Default* |
     | ="..."= or%BR% =refresh="..."= | Cache refresh period in hours (maximum age of cache) | =REFRESH= setting |
     | =cachemsg="..."= | Message shown when looking at a cached topic. Use =$age= to indicate the age of cache, =$link= to indicate the refresh URL | =CACHEMSG= setting |
     | =updatemsg="..."= | Message shown after a cache refresh. Use =$link= to indicate the refresh URL | =UPDATEMSG= setting |
   * Example: =%<nop>VARCACHE{"168"}%= caches the current page for 7 days
   * Exclude variables from getting cached:
      * Use =&lt;varcache_exclude&gt; ... &lt;/varcache_exclude&gt;= to exclude sections of a page
         * Example: =&lt;varcache_exclude&gt; %<nop>SEARCH{...}% &lt;/varcache_exclude&gt;= runs the search on every page view, regardless of caching
      * Or, prefix variables with =VARCACHE_EXCLUDE_=
         * Example: =%<nop>VARCACHE_EXCLUDE_WIKIUSERNAME%= renders the =WIKIUSERNAME= variable on every page view, regardless of caching
   * Category: AdministrationVariables, DevelopmentVariables
   * Related: VarCachePlugin, VarCachePluginTest
