A WordPress-centric search engine for devs and theme authors



update_sitemeta_cache ›

Since5.0.0
Deprecatedn/a
update_sitemeta_cache ( $site_ids )
Parameters:
  • (array) $site_ids List of site IDs.
    Required: Yes
Returns:
  • (array|false) Returns false if there is nothing to update. Returns an array of metadata on success.
Defined at:
Codex:

Updates metadata cache for list of site IDs.

Performs SQL query to retrieve all metadata for the sites matching $site_ids and stores them in the cache. Subsequent calls to get_site_meta() will not need to query the database.



Source

function update_sitemeta_cache( $site_ids ) {
	if ( ! is_site_meta_supported() ) {
		return false;
	}

	return update_meta_cache( 'blog', $site_ids );
}