WordPress at a glance
filter is not described

style_loader_tag filter-hook . WP 2.6.0

Filters the HTML link tag of an enqueued style.

Usage

add_filter( 'style_loader_tag', 'filter_function_name_6649', 10, 4 );
function filter_function_name_6649( $html, $handle, $href, $media ){
	// filter...

	return $html;
}
$html(string)
The link tag for the enqueued style.
$handle(string)
The style's registered handle.
$href(string)
The stylesheet's source URL.
$media(string)
The stylesheet's media attribute.

Notes

  • Since 4.3.0 Introduced the $href parameter.
  • Since 4.5.0 Introduced the $media parameter.

Where the hook is called

WP_Styles::do_item()
wp-includes/class.wp-styles.php 191
$tag = apply_filters( 'style_loader_tag', "<link rel='$rel' id='$handle-css' $title href='$href' type='text/css' media='$media' />\n", $handle, $href, $media);
wp-includes/class.wp-styles.php 201
$rtl_tag = apply_filters( 'style_loader_tag', "<link rel='$rel' id='$handle-rtl-css' $title href='$rtl_href' type='text/css' media='$media' />\n", $handle, $rtl_href, $media );

Where the hook is used (in WP core)

Does not used.