stylesheet
Filters the name of current stylesheet.
Usage
add_filter( 'stylesheet', 'wp_kama_stylesheet_filter' ); /** * Function for `stylesheet` filter-hook. * * @param string $stylesheet Name of the current stylesheet. * * @return string */ function wp_kama_stylesheet_filter( $stylesheet ){ // filter... return $stylesheet; }
- $stylesheet(string)
- Name of the current stylesheet.
Changelog
Since 1.5.0 | Introduced. |
Where the hook is called
stylesheet
wp-includes/theme.php 189
return apply_filters( 'stylesheet', get_option( 'stylesheet' ) );
Where the hook is used in WordPress
wp-includes/class-wp-customize-manager.php 689
add_filter( 'stylesheet', array( $this, 'get_stylesheet' ) );
wp-includes/class-wp-customize-manager.php 727
remove_filter( 'stylesheet', array( $this, 'get_stylesheet' ) );
wp-includes/theme-previews.php 88
add_filter( 'stylesheet', 'wp_get_theme_preview_path' );