WP_User::for_blog
Deprecated since 4.9.0. It is no longer supported and may be removed in future releases. Use WP_User::for_site() instead.
Sets the site to operate on. Defaults to the current site.
Method of the class: WP_User{}
No Hooks.
Returns
null. Nothing (null).
Usage
$WP_User = new WP_User(); $WP_User->for_blog( $blog_id );
- $blog_id(int)
- Site ID.
Default:current site
Changelog
| Since 3.0.0 | Introduced. |
| Deprecated since 4.9.0 | Use WP_User::for_site() |
WP_User::for_blog() WP User::for blog code WP 6.9.1
public function for_blog( $blog_id = 0 ) {
_deprecated_function( __METHOD__, '4.9.0', 'WP_User::for_site()' );
$this->for_site( $blog_id );
}