WordPress开发者和主题制作者的搜索引擎



wp_cache_switch_to_blog ›

Since3.5.0
已弃用n/a
wp_cache_switch_to_blog ( $blog_id )
参数:
  • (int) $blog_id Site ID.
    Required: Yes
查看:
定义在:
文档:

Switches the internal blog ID.

This changes the blog id used to create keys in blog specific groups.



源码

function wp_cache_switch_to_blog( $blog_id ) {
	global $wp_object_cache;

	$wp_object_cache->switch_to_blog( $blog_id );
}