get_networks( string|array $args = array() )

Retrieves a list of networks.


Description Description


Parameters Parameters

$args

(string|array) (Optional) Array or string of arguments. See WP_Network_Query::parse_query() for information on accepted arguments.

Default value: array()


Top ↑

Return Return

(array|int) List of WP_Network objects, a list of network ids when 'fields' is set to 'ids', or the number of networks when 'count' is passed as a query var.


Top ↑

Source Source

File: wp-includes/ms-network.php

function get_networks( $args = array() ) {
	$query = new WP_Network_Query();

	return $query->query( $args );
}

Top ↑

Changelog Changelog

Changelog
Version Description
4.6.0 Introduced.


Top ↑

User Contributed Notes User Contributed Notes

You must log in before being able to contribute a note or feedback.