get_current_site()WP 3.0.0

Gets the current network.

Returns an object containing the 'id', 'domain', 'path', and 'site_name' properties of the network being viewed.

Хуков нет.

Возвращает

WP_Network. The current network.

Использование

get_current_site();

Заметки

Список изменений

С версии 3.0.0 Введена.

Код get_current_site() WP 6.5.2

function get_current_site() {
	global $current_site;
	return $current_site;
}