WordPress.org

Support

Support » Plugins and Hacks » [feature request] clear supercache when announcement changes

[feature request] clear supercache when announcement changes

  • James Revillini
    Participant

    @jrevillini

    Plugin rocks. It would be great if it cleared the supercache cache so that there is not a delay in announcements going up/down/changing. Here is the code I added to my theme’s functions.php file:

    function ninja_annc_clear_cache ( $post_id ) {
    	if (get_post_type( $post_id ) == 'ninja_annc') wp_cache_clear_cache();
    }
    add_action( 'edit_post', 'ninja_annc_clear_cache' );

    My code may not cover all situations and it’s probably overkill to clear cache upon every update instead of just at status changes. Also, to make it more configurable, it should be an option in the plugin settings.

    http://wordpress.org/extend/plugins/ninja-announcements/

Viewing 1 replies (of 1 total)
  • Plugin Author Kevin Stover
    Participant

    @kstover

    Thanks for the heads up! I agree, there are a ton of things we can add to make this plugin more awesome. We recently completed a re-write of another plugin, and that has kept us super busy. We plan on re-visiting Ninja Announcements in the near future. It will probably get a complete re-write as well.

Viewing 1 replies (of 1 total)
  • The topic ‘[feature request] clear supercache when announcement changes’ is closed to new replies.