Used By
| Used By | Description |
|---|---|
| wp-includes/template.php: get_query_template() | Retrieve path to a template |
Filters the path of the queried template by type.
The dynamic portion of the hook name, $type, refers to the filename — minus the file extension and any non-alphanumeric characters delimiting words — of the file to load. This hook also applies to various types of files loaded as part of the Template Hierarchy.
Possible values for $type include: ‘index’, ‘404’, ‘archive’, ‘author’, ‘category’, ‘tag’, ‘taxonomy’, ‘date’, ’embed’, ‘home’, ‘frontpage’, ‘privacypolicy’, ‘page’, ‘paged’, ‘search’, ‘single’, ‘singular’, and ‘attachment’.
(string) Path to the template. See locate_template().
(string) Sanitized filename without extension.
(array) A list of template candidates, in descending order of priority.
File: wp-includes/template.php
| Version | Description |
|---|---|
| 4.8.0 | The $type and $templates parameters were added. |
| 1.5.0 | Introduced. |
© 2003–2019 WordPress Foundation
Licensed under the GNU GPLv2+ License.
https://developer.wordpress.org/reference/hooks/type_template