A WordPress-centric search engine for devs and theme authors



get_queried_object ›

Since3.1.0
Deprecatedn/a
get_queried_object ( No parameters )
Returns:
  • (object) Queried object.
Defined at:
Codex:

Retrieve the currently-queried object.

Wrapper for WP_Query::get_queried_object().



Source

function get_queried_object() {
	global $wp_query;
	return $wp_query->get_queried_object();
}