template_directory_uri WordPress Filter Hook

The template_directory_uri hook is used to retrieve the URL of the current theme's directory. This can be useful when needing to reference theme files such as CSS or JavaScript files.

apply_filters( 'template_directory_uri', string $template_dir_uri, string $template, string $theme_root_uri ) #

Filters the active theme directory URI.


Parameters

$template_dir_uri

(string)The URI of the active theme directory.

$template

(string)Directory name of the active theme.

$theme_root_uri

(string)The themes root URI.


Top ↑

Source

File: wp-includes/theme.php

View on Trac



Top ↑

Changelog

Changelog
VersionDescription
1.5.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.

Show More