So i have a general caching question and perhaps it will lead to some implementation solution:
From what i’ve noticed while playing around with modx’s caching techniques, it seems to me that each cached page is not user specific cache.
Meaning, if web user A was to log in, and then web user content was to display and the page gets cached (assuming it was not previously cached), then when a random user hits that same page (regardless if they are logged in or not), web user content will still show because the page is being delivered from cached (generated by user A).
Is there a way to make all cached pages user specific? Or is this redundant?
-
MODX Staff
- 10,725 Posts
No, there is no user specific cache, and yes, it would be redundant. The typical rule is, don’t cache content that changes (i.e. is dynamic), whether it be date-based, or based on the user, or based on any-other information that would cause the content to render differently or different content to be rendered altogether. Cache what you can and mark the rest uncached as needed (i.e. [!UncachedSnippet!] vs [[CachedSnippet]]; that’s what partial page caching is all about.