wp-includes/rest-api.php:
rest_get_queried_resource_route()
|
Gets the REST route for the currently queried object.
|
wp-includes/widgets/class-wp-widget-custom-html.php:
WP_Widget_Custom_HTML::widget()
|
Outputs the content for the current Custom HTML widget instance.
|
wp-includes/template.php:
get_embed_template()
|
Retrieves an embed template path in the current or parent template.
|
wp-includes/general-template.php:
wp_get_document_title()
|
Returns document title for the current page.
|
wp-includes/general-template.php:
get_the_archive_title()
|
Retrieve the archive title based on the queried object.
|
wp-includes/category-template.php:
term_description()
|
Retrieves term description.
|
wp-includes/category-template.php:
wp_list_categories()
|
Displays or retrieves the HTML list of categories.
|
wp-includes/general-template.php:
feed_links_extra()
|
Display the links to the extra feeds such as category feeds.
|
wp-includes/general-template.php:
wp_title()
|
Display or retrieve page title for all areas of blog.
|
wp-includes/general-template.php:
single_post_title()
|
Display or retrieve page title for post.
|
wp-includes/general-template.php:
single_term_title()
|
Display or retrieve page title for taxonomy term archive.
|
wp-includes/class-wp.php:
WP::handle_404()
|
Set the Headers for 404, if nothing is found for requested URL.
|
wp-includes/widgets/class-wp-widget-text.php:
WP_Widget_Text::widget()
|
Outputs the content for the current Text widget instance.
|
wp-includes/link-template.php:
edit_term_link()
|
Displays or retrieves the edit term link with formatting.
|
wp-includes/template.php:
get_single_template()
|
Retrieve path of single template in current or parent template. Applies to single Posts, single Attachments, and single custom post types.
|
wp-includes/template.php:
get_attachment_template()
|
Retrieve path of attachment template in current or parent template.
|
wp-includes/template.php:
get_author_template()
|
Retrieve path of author template in current or parent template.
|
wp-includes/template.php:
get_category_template()
|
Retrieve path of category template in current or parent template.
|
wp-includes/template.php:
get_tag_template()
|
Retrieve path of tag template in current or parent template.
|
wp-includes/template.php:
get_taxonomy_template()
|
Retrieve path of custom taxonomy term template in current or parent template.
|
wp-includes/template.php:
get_page_template()
|
Retrieve path of page template in current or parent template.
|
wp-includes/post-template.php:
wp_list_pages()
|
Retrieve or display a list of pages (or hierarchical post type items) in list (li) format.
|
The “currently-queried object” means the object that is the subject of the webpage:
– On a category archive, tag archive, or other taxonomy archive page, it will return the
WP_Term
object of the current category, tag, or other term.– If you have set a posts page where your basic posts are displayed,
get_queried_object()
will return theWP_Post
object of that page.– On post type archive pages, it will return the
WP_Post_Type
object of the given post type.– On an author archive page, it will return the
WP_User
object of that author.– On any singular page (a single post, a single page, or a post in a custom post type), it will return the
WP_Post
object of that post or page.Be careful not to use
get_queried_object()
andget_post()
orglobal $post
interchangeably. On a singular post, those will all return the same thing. But, for example, if you have a page called “Blog” that displays your posts,get_queried_object()
will return the “Blog” page whereasget_post()
will return the current post in the loop.