WP_User::get_site_id()publicWP 4.9.0

Gets the ID of the site for which the user's capabilities are currently initialized.

Method of the class: WP_User{}

No Hooks.

Return

Int. Site ID.

Usage

$WP_User = new WP_User();
$WP_User->get_site_id();

Changelog

Since 4.9.0 Introduced.

WP_User::get_site_id() code WP 6.5.2

public function get_site_id() {
	return $this->site_id;
}