bp_core_clear_cache()

Prune the WP Super Cache.

Description

When WP Super Cache is installed, this function will clear cached pages so that success/error messages or time-sensitive content are not cached.

See also

Return

(int)

Source

File: bp-core/bp-core-cache.php

function bp_core_clear_cache() {
	global $cache_path;

	if ( function_exists( 'prune_super_cache' ) ) {

		/**
		 * Fires before the pruning of WP Super Cache.
		 *
		 * @since BuddyPress 1.0.0
		 */
		do_action( 'bp_core_clear_cache' );
		return prune_super_cache( $cache_path, true );
	}
}

Changelog

Changelog
Version Description
BuddyPress 1.0.0 Introduced.

Questions?

We're always happy to help with code or other questions you might have! Search our developer docs, contact support, or connect with our sales team.