WordPress at a glance
function is not described

WP_Site_Query::parse_query() WP 4.6.0

Parses arguments passed to the site query with default query parameters.

This is a method of the class: WP_Site_Query

Hooks from the method
Return

Null. Nothing.

Usage

$WP_Site_Query = new WP_Site_Query();
$var = $WP_Site_Query->parse_query( $query );
$query(string/array)
Array or string of WP_Site_Query arguments. See WP_Site_Query::__construct().
Default: ''

Notes

  • See: WP_Site_Query::__construct()

Changelog

Since 4.6.0 Introduced.

Code of WP Site Query::parse query: wp-includes/class-wp-site-query.php WP 5.4.1

<?php
public function parse_query( $query = '' ) {
	if ( empty( $query ) ) {
		$query = $this->query_vars;
	}

	$this->query_vars = wp_parse_args( $query, $this->query_var_defaults );

	/**
	 * Fires after the site query vars have been parsed.
	 *
	 * @since 4.6.0
	 *
	 * @param WP_Site_Query $this The WP_Site_Query instance (passed by reference).
	 */
	do_action_ref_array( 'parse_site_query', array( &$this ) );
}