WP HOOKS
filtrod 2.5.0

mce_external_languages

Args 2Plik wp-includes/class-wp-editor.phpDokumentacja WP ↗

Opis — z kodu źródłowego

Filters the translations loaded for external TinyMCE 3.x plugins.

The filter takes an associative array ('plugin_name' => 'path') where 'path' is the include path to the file. The language file should follow the same format as wp_mce_translation(), and should define a variable ($strings) that holds all translated strings.

Parametry

ParametrTypOpis
$translationsarrayTranslations for external TinyMCE plugins.
$editor_idstringUnique editor identifier, e.g. 'content'.

Wywołanie

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

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