locked
Clear OutputCache RRS feed

  • Question

  • User-640622294 posted

    Hi guys

    How can i remove many outputCache from controller after create news(post)

    this code does not work !

                        var urlToRemoveIndexHome = Url.Action("Index", "Home");
                        HttpResponse.RemoveOutputCacheItem(urlToRemoveIndexHome);
    
                        var urlToRemoveBlogTag = Url.Action("Tag", "BlogController");
                        HttpResponse.RemoveOutputCacheItem(urlToRemoveBlogTag);

    Monday, January 21, 2019 3:34 PM

Answers

  • User-640622294 posted

    HttpRuntime.Close();

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Monday, January 21, 2019 4:39 PM

All replies

  • User753101303 posted

    Hi,

    And what have you done to cache this ? Does it make sense to put that in cache and remove it rather than to not cache this which is maybe not the best thing you could cache ?

    Edit: more explictely I suspect it is perhaps cached client side rather than server side ???

    Monday, January 21, 2019 4:07 PM
  • User-640622294 posted

    HttpRuntime.Close();

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Monday, January 21, 2019 4:39 PM