I've added below one in web.config
<staticContent>
<clientCache cacheControlMode="UseMaxAge" cacheControlMaxAge="10.00:00:00" />
</staticContent>
But I'm not seeing expires on response headers. Should I do any other changes?
I would try two things to debug. First I would change cacheControlCustom from private
to public
<location path="Content">
<system.webServer>
<staticContent>
<clientCache
cacheControlCustom="public"
cacheControlMode="UseMaxAge"
cacheControlMaxAge="10.00:00:00" />
</staticContent>
</system.webServer>
</location>
If that does not work check the location of your path covered for caching. Your example is not showing that part.
Lastly, try to unlock StaticContent section of machine config via:
appcmd unlock config /section:staticContent
Here is a link with some additional useful information Client Cache.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With