You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
i want to change the duration of DonutOutputCache attribute from database record.
so i just write a custom outputcache which is childof DonutOutputCacheAttribute :
public class CmsOutputCache : DonutOutputCacheAttribute
{
public CmsOutputCache()
{
var setting = SettingBL.GetAdvancedSetting();
this.Duration = setting.TimeCache * 15;
}
}
and use it like this :
[ChildActionOnly]
[CmsOutputCache]
public ActionResult HeaderSlider(){}
but the behavior of caching not working now!
how to set duration?
The text was updated successfully, but these errors were encountered:
i want to change the duration of DonutOutputCache attribute from database record.
so i just write a custom outputcache which is childof DonutOutputCacheAttribute :
public class CmsOutputCache : DonutOutputCacheAttribute
{
public CmsOutputCache()
{
var setting = SettingBL.GetAdvancedSetting();
this.Duration = setting.TimeCache * 15;
and use it like this :
[ChildActionOnly]
[CmsOutputCache]
public ActionResult HeaderSlider(){}
but the behavior of caching not working now!
how to set duration?
The text was updated successfully, but these errors were encountered: