mce_external_languages
Проверено на WordPress 6.9, обновлено Источник: WordPress Developer Resources.
Сигнатура
apply_filters( 'mce_external_languages', array $translations, string $editor_id )
Описание
Фильтр принимает ассоциативный массив ('plugin_name' => 'path'), где 'path' — путь для подключения файла.
Языковой файл должен следовать тому же формату, что и wp_mce_translation(), и определять переменную ($strings), содержащую все переведённые строки.
Оригинал (английский)
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.
Фильтруемое значение
Параметры
$translations
array
обязательный
$editor_id
string
обязательный
Исходный код
wp-includes/class-wp-editor.php:489
$mce_external_languages = apply_filters( 'mce_external_languages', array(), $editor_id );
История изменений
| Версия | Описание |
|---|---|
| 5.3.0 | The $editor_id parameter was added. |
| 2.5.0 | Introduced. |

