WordPress at Your Fingertips

get_template() WP 1.0

Retrieve name of the current theme.

1 time — 0.0022421 sec (very slow) | 50000 times — 2.09 sec (fast) | PHP 7.3.20, WP 5.6
Hooks from the function
Return

String. Template name.

Usage

get_template();

Changelog

Since 1.5.0 Introduced.

Code of get_template() WP 5.8

<?php
function get_template() {
	/**
	 * Filters the name of the current theme.
	 *
	 * @since 1.5.0
	 *
	 * @param string $template Current theme's directory name.
	 */
	return apply_filters( 'template', get_option( 'template' ) );
}

From tag: path (directory folder)

More from category: Other Theme Functions

No comments
    Log In