get_site
get_site ( $site = null )
Parameters:- (WP_Site|int|null) site Optional. Site to retrieve. Default is the current site.
Returns:- (WP_Site|null) The site object or null if not found.
Defined at: - Introduced in WordPress: 4.6.0
- Deprecated in WordPress: —
Description
Retrieves site data given a site ID or site object.Site data will be cached and returned after being passed through a filter.
If the provided site is empty, the current site global will be used.