Clear cache programatically
-
I found this code that is supposed to clear the cache, either fully, or per postID (page)
It doesn’t seem to be doing so for me.
// initilize WordPress environment if (!defined('ABSPATH')) { require_once('./wp-load.php'); } if (has_action('ce_clear_cache')) { do_action('ce_clear_cache'); } if (has_action('ce_clear_post_cache')) { do_action('ce_clear_post_cache', 1111); // post_id }Found here
I can confirm that the action does exist, via has_action()
Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
The topic ‘Clear cache programatically’ is closed to new replies.