style_loader_src WordPress Filter Hook

The style_loader_src hook is used to modify the URL of the stylesheet. This can be useful for loading a different stylesheet based on the current page template or post type.

apply_filters( 'style_loader_src', string $src, string $handle ) #

Filters an enqueued style’s fully-qualified URL.


Parameters

$src

(string)The source URL of the enqueued style.

$handle

(string)The style's registered handle.


Top ↑

Source

File: wp-includes/class.wp-styles.php

View on Trac



Top ↑

Changelog

Changelog
VersionDescription
2.6.0Introduced.

The content displayed on this page has been created in part by processing WordPress source code files which are made available under the GPLv2 (or a later version) license by theĀ Free Software Foundation. In addition to this, the content includes user-written examples and information. All material is subject to review and curation by the WPPaste.com community.