Press Ctrl / CMD + C to copy this to your clipboard.
This post will be reported to the moderators as potential spam to be looked at
I've taken over development of an Umbraco 8 application and have run into the following problem:
All partial views are rendered as CachedParial with a time of 60 secs.
If I do a search using the searchbar we have, the results are returned ok, but when I try to click away to any other page in the app, the search page remains for that 60 secs, after which I can click to home or where ever.
What's best to do here, use partial instead of CachedPartial for the container holding the search results and the search bar?
Yes you answered your question. You can use Partial instead of Cached Partial for Search.
That's weird, at our company we are using CahedPartials too and we do not have that issue. Can you please provide more details about your implementation?
I think the problem (now resolved, but I dont like how I resolved it) is this:
The main home page contains several partials, including a top nav bar with a search, and a central container which changes depending on the content.
When you enter search criteria and click a button, the container is updated and shows the search results.
But as the main page contains all cached partials set at a time of 60 seconds, if I then click a 'home' button or try another search (bear in mind all this would happen on the one page), the cached partials are reloaded showing the last search criteria and results, this will happen for the next 60 seconds.
I got round it by setting the cache time in webconfig to 0, but I'm not happy with that, I'm guessing there is a way to reload the entire page and reset the cached partials within it?
You can vary the cache, by a query string parameter.
It's just an additional attribute you can set on Cached Partials.
is working on a reply...
Write your reply to:
Image will be uploaded when post is submitted