Smart    Lucky

Smart Lucky

  • NA
  • 555
  • 626.7k

Client Cache Not Working for StaticContent

Aug 12 2014 12:48 AM
Hi dudes
 
I am i have an mvc application (with NHibernate) i want to enable client cache for static contents using web config but it is not working , blow code i have wrote , can any one help please
 
 
 
 
 
<location path="Content/css">
<system.webServer>
<staticContent>
<clientCache cacheControlMode="UseMaxAge" cacheControlMaxAge="30.00:00:00" />
</staticContent>
</system.webServer>
</location>
<location path="Scripts">
<system.webServer>
<staticContent>
<clientCache cacheControlMode="UseMaxAge" cacheControlMaxAge="30.00:00:00" />
</staticContent>
</system.webServer>
</location>
<location path="images">
<system.webServer>
<staticContent>
<clientCache cacheControlMode="UseMaxAge" cacheControlMaxAge="30.00:00:00" />
</staticContent>
</system.webServer>
</location>