get_query_template( string $type, array $templates = array() )

Retrieve path to a template

25 related functions found for: get_query_template

Top ↑

Related terms found for this post

wp-parser-related-wordsget, queri, query, templat, template, template-php, wp-includes
wp-parser-packageTemplate, WordPress

Top ↑

Terms Used Terms Used

Terms used in the related posts query

  • get
  • queri
  • query
  • templat
  • template
  • Template
  • template-php
  • wp-includes
  • wp-includes/template.php

Top ↑

Description Description

Used to quickly retrieve the path of a template without including the file extension. It will also check the parent theme, if the file exists, with the use of locate_template(). Allows for more generic template location without the use of the other get_*_template() functions.

Top ↑

Parameters Parameters


(string) (Required) Filename without extension.


(array) (Optional) An optional list of template candidates

Default value: array()

Top ↑

Return Return

(string) Full path to template file.

Top ↑

Source Source

File: wp-includes/template.php


Top ↑

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.