WordPress at a glance

get_stylesheet() WP 1.0

Retrieve name of the current stylesheet.

The theme name that the administrator has currently set the front end theme as.

For all intents and purposes, the template name and the stylesheet name are going to be the same for most cases.

✈ 1 time = 0.003651s = very slow | 50000 times = 1.97s = fast PHP 7.1.5, WP 4.8.2

No Hooks.

Return

String. Stylesheet name.

Usage

get_stylesheet();

Code of get_stylesheet: wp-includes/theme.php VER 5.0.1

<?php
function get_stylesheet() {
	/**
	 * Filters the name of current stylesheet.
	 *
	 * @since 1.5.0
	 *
	 * @param string $stylesheet Name of the current stylesheet.
	 */
	return apply_filters( 'stylesheet', get_option( 'stylesheet' ) );
}

Related Functions

From category: Other Theme Functions

No comments
    Hello, !     Log In . Register