+1-888-365-2779
Try Now
More in this section

Forums / Bugs & Issues / Sitefinity MVC Feather Widgets - prevent caching

Sitefinity MVC Feather Widgets - prevent caching

3 posts, 0 answered
  1. Adam
    Adam avatar
    23 posts
    Registered:
    05 Apr 2013
    18 Aug
    Link to this post
    I'm using the feather package and building feather widgets for Sitefinity 9.1. I can't seem to override the Output Cache for the widgets using the OutputCache attribute: [OutputCache(NoStore = true, Duration = 0, VaryByParam = "*")]. I don't want to have to disable caching at the page level, just at the widget level. How do I disable caching at the widget level in Sitefinity?
  2. Bartłomiej
    Bartłomiej avatar
    0 posts
    Registered:
    07 May 2015
    14 Sep
    Link to this post

    I have the same requirement on the controller action method.

    I'm using 9.1 and 8.2 Sitefinity.

  3. Adam
    Adam avatar
    23 posts
    Registered:
    05 Apr 2013
    14 Sep
    Link to this post
    So, I ended up using a combination of listening for the "PageManager.Executing" event in the global.asax (http://docs.sitefinity.com/tutorial-subscribe-to-events-using-dataprovider-or-manager-class & https://www.americaneagle.com/blog/web-development-blog/alex-hawley/2016/06/29/clear-a-page-s-output-cache-programmatically-in-sitefinity)  and adding cache dependencies to my mvc widget (http://docs.sitefinity.com/for-developers-implement-cache-dependencies) to un-cache the pages. 
3 posts, 0 answered