WP HOOKS
filtrod 6.5.0

translation_file_format

Args 2Plik wp-includes/l10n.phpDokumentacja WP ↗

Opis — z kodu źródłowego

Filters the preferred file format for translation files.

Can be used to disable the use of PHP files for translations.

Parametry

ParametrTypOpis
$preferred_formatstringPreferred file format. Possible values: 'php', 'mo'. Default: 'php'.
$domainstringThe text domain.

Wywołanie

Rejestracja callbackaphp
// rejestracja funkcji zwrotnej — podaj liczbę argumentów!
add_filter( 'translation_file_format', 'twoja_funkcja', 10, 2 );

function twoja_funkcja($param_1, $param_2) {
	// Twój kod
}

Popularne w tej kategorii