How set the response header's Cache-Control in Sitecore?
- by user822211
By default, it looks like Sitecore does not cache pages. In web.config, set this
<setting name="DisableBrowserCaching" value="false"/>
and create pipeline processor
page.Response.Cache.SetExpires(DateTime.Now.AddSeconds(60));
page.Response.Cache.SetCacheability(HttpCacheability.Public);
but it did not work, the repose head stays no-cache. By the way, I add the pipeline in the renderLayout, anyone knows? thanks!