I have a ViewPage that contains <% Html.RenderAction<MyController>(c => c.SidebarStats()); %>
. On the controller action for the action SidebarStats I have an OutputCache action filter to cache only that part of the page. However, the whole page is getting cached and not just that action.
I remember seeing somewhere that this might be a bug with ASP.NET MVC though I'm not sure. I'm currently using ASP.NET MVC RC1, IIS7, Windows Server 2008 and .NET 3.5 SP1.
I blogged a solution to this problem here. It's simple, but it only works if you're using the WebFormViewEngine. We will look hard into figuring out what it will take to make this work for all view engines.
According to Microsoft this is a known bug with no known fix. Only workarounds suggested are to create your own OutputCache action filter.
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