is_textdomain_loaded() WordPress Function

is_textdomain_loaded() is a function that checks if a given textdomain has been loaded. This is useful for checking if a plugin or theme has been loaded before using it.

is_textdomain_loaded( string $domain ) #

Whether there are translations for the text domain.


Parameters

$domain

(string)(Required)Text domain. Unique identifier for retrieving translated strings.


Top ↑

Return

(bool) Whether there are translations.


Top ↑

Source

File: wp-includes/l10n.php

function is_textdomain_loaded( $domain ) {
	global $l10n;
	return isset( $l10n[ $domain ] );
}


Top ↑

Changelog

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