lang_dir_for_domain filter-hookWP 6.6.0

Filters the determined languages directory path for a specific domain and locale.

Usage

add_filter( 'lang_dir_for_domain', 'wp_kama_lang_dir_for_domain_filter', 10, 3 );

/**
 * Function for `lang_dir_for_domain` filter-hook.
 * 
 * @param string|false $path   Languages directory path for the given domain and locale.
 * @param string       $domain Text domain.
 * @param string       $locale Locale.
 *
 * @return string|false
 */
function wp_kama_lang_dir_for_domain_filter( $path, $domain, $locale ){

	// filter...
	return $path;
}
$path(string|false)
Languages directory path for the given domain and locale.
$domain(string)
Text domain.
$locale(string)
Locale.

Changelog

Since 6.6.0 Introduced.

Where the hook is called

WP_Textdomain_Registry::get()
lang_dir_for_domain
wp-includes/class-wp-textdomain-registry.php 105
return apply_filters( 'lang_dir_for_domain', $path, $domain, $locale );

Where the hook is used in WordPress

Usage not found.