Super Cache and Dynamic Include
Trying to use WP-Cache 2 with some dynamic portions of the page. I am using the mclude commands, but am running into confusion on exactly what is allowed to go into the PHP file that I am including.
The problem is that my site has a “welcome back…” statement on it, plus the ads disappear, depending on a person’s privledges. So, ideally, I would have fully cached pages ONLY when the person is not logged in at all. If they ARE logged in, then everything stays fully dynamic.
Unfortunately, it seems WP-Cache is an all-or-nothing, which means its going to cache regardless whether the user is logged in. And that means I have to look at making portions of the page dynamic.
So, in the PHP file that I try to include, I have a call to get_currentuserinfo(). That halts execution and makes the page fail to load, guessing because it cannot find that function. But, without running a function to query for user privledges, I can’t welcome anybody back or make anything dynamic because I don’t know who the user is.
So, I guess these are my questions:
(1) Is there a way to leave the entire site fully dynamic if the user is logged in at all, but only raw users get a cached version?
(2) In using Wp-Cache 2, is there a way I can execute external functions (functions which are part of the WP core) inside the file which is included using mclude?
Thanks for ANY help. I’ve literally wasted 3 hours on this this afternoon.
- The topic ‘Super Cache and Dynamic Include’ is closed to new replies.