Feature Request : Cache Only Specific Posts
-
Hi,
I have been using Super Cache for a while now. I am on a VPS and my regular traffic levels are easily handled by my server. But at times a few posts of mine get dugg, and I’d like to enable WP-Cache only on those posts.
Please add this as a feature similar in line to the Rejected URI’s. I’d like to enable WP-Cache only for specific posts which i’m expecting to be dugg.
This is what I tried doing by editing wp cache phase 2 file :
function wp_cache_is_rejected($uri) { global $cache_rejected_uri; if (strstr($uri, '/wp-admin/')) return true; // we don't allow caching of wp-admin for security reasons foreach ($cache_rejected_uri as $expr) { if( preg_match( "~$expr~", $uri ) ) return false; } return true; }
And then added the URI of my post into the rejected URI field in the admin. It partially works, It doesn’t cache the rest of the blog, but only half of the post is cached
Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
- The topic ‘Feature Request : Cache Only Specific Posts’ is closed to new replies.