WP_Query::__construct( string|array $query = '' )

Constructor.


Description Description

Sets up the WordPress query, if parameter is not empty.


Parameters Parameters

$query

(string|array) (Optional) URL query string or array of vars.

Default value: ''


Top ↑

Source Source

File: wp-includes/class-wp-query.php

	public function __construct( $query = '' ) {
		if ( ! empty( $query ) ) {
			$this->query( $query );
		}
	}

Top ↑

Changelog Changelog

Changelog
Version Description
1.5.0 Introduced.


Top ↑

User Contributed Notes User Contributed Notes

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