[wp-hackers] Is it possible to cache wp_query object?
technocraze at gmail.com
Thu May 14 09:15:00 GMT 2009
I was working on caching the posts permanently until it is updated or
deleted and to use that cache for serving the requests. In wordpress,
whenever a page is requested, the wp_query() is called, and hence even
caching of individual posts would not be useful.
I had an idea of caching the wp_query and wp objects , and using the
init hook, restore it from cache for the subsequent requests. I wanted
to have your views on it, whether its feasible, or is there any other
dependencies. When i looked further, i find that the function wp()
initialises ( $wp->init() ) the user details, which is different for
each request. Other than that, is there any other dynamic data stored
in these two objects?
More information about the wp-hackers