WordPress как на ладони
Недорогой хостинг для сайтов на WordPress: wordpress.jino.ru
фильтр не описан

(type)_template хук-фильтр . WP 1.5.0

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'.

Использование

add_filter( '(type)_template', 'filter_function_name_8856', 10, 3 );
function filter_function_name_8856( $template, $type, $templates ){
	// filter...

	return $template;
}
$template(строка)
Path to the template. See locate_template().
$type(строка)
Sanitized filename without extension.
$templates(массив)
A list of template candidates, in descending order of priority.

Список изменений

С версии 1.5.0 Введена.
С версии 4.8.0 The $type and $templates parameters were added.

Где вызывается хук

get_query_template()
(type)_template
wp-includes/template.php 63
return apply_filters( "{$type}_template", $template, $type, $templates );

Где используется хук (в ядре WP)

wp-includes/class-wp-customize-manager.php 676
add_filter( 'template', array( $this, 'get_template' ) );
wp-includes/class-wp-customize-manager.php 682
add_filter( 'pre_option_template', array( $this, 'get_template' ) );
wp-includes/class-wp-customize-manager.php 714
remove_filter( 'template', array( $this, 'get_template' ) );
wp-includes/class-wp-customize-manager.php 720
remove_filter( 'pre_option_template', array( $this, 'get_template' ) );
wp-includes/class-wp-customize-nav-menus.php 65
add_action( 'customize_controls_print_footer_scripts', array( $this, 'available_items_template' ) );
wp-includes/customize/class-wp-customize-header-image-control.php 107
add_action( 'customize_controls_print_footer_scripts', array( $this, 'print_header_image_template' ) );