LOCALE_TRANSLATION_OVERWRITE_ALL

UI option for override of existing translations. Override any translation. File core/modules/locale/locale.module, line 112 Enables the translation of the user interface to languages other than English. Code const LOCALE_TRANSLATION_OVERWRITE_ALL = 'all';

locale_translation_manual_status

locale_translation_manual_status() Page callback: Checks for translation updates and displays the status. Manually checks the translation status without the use of cron. See also locale_menu() File core/modules/locale/locale.pages.inc, line 18 Interface translation summary, editing and deletion user interfaces. Code function locale_translation_manual_status() { module_load_include('compare.inc', 'locale'); // Check the translation status of all translatable projects in all languages.

LOCALE_TRANSLATION_LOCAL

Translation source is a local file. File core/modules/locale/locale.module, line 134 Enables the translation of the user interface to languages other than English. Code const LOCALE_TRANSLATION_LOCAL = 'local';

locale_translation_load_sources

locale_translation_load_sources(array $projects = NULL, array $langcodes = NULL) Loads cached translation sources containing current translation status. Parameters array $projects: Array of project names. Defaults to all translatable projects. array $langcodes: Array of language codes. Defaults to all translatable languages. Return value array Array of source objects. Keyed with <project name>:<language code>. See also locale_translation_source_build() File core/modules/locale/lo

locale_translation_language_table

locale_translation_language_table($form_element) Form element callback: After build changes to the language update table. Adds labels to the languages and removes checkboxes from languages from which translation files could not be found. File core/modules/locale/locale.module, line 1393 Enables the translation of the user interface to languages other than English. Code function locale_translation_language_table($form_element) { // Remove checkboxes of languages without updates. if ($form_

locale_translation_http_check

locale_translation_http_check($uri) Check if remote file exists and when it was last updated. Parameters string $uri: URI of remote file. Return value array|bool Associative array of file data with the following elements: last_modified: Last modified timestamp of the translation file. (optional) location: The location of the translation file. Is only set when a redirect (301) has occurred. TRUE if the file is not found. FALSE if a fault occurred. File core/modules/locale/locale.batch.inc,

locale_translation_get_status

locale_translation_get_status($projects = NULL, $langcodes = NULL) Gets the current translation status. @todo What is 'translation status'? File core/modules/locale/locale.module, line 882 Enables the translation of the user interface to languages other than English. Code function locale_translation_get_status($projects = NULL, $langcodes = NULL) { $result = array(); $status = \Drupal::state()->get('locale.translation_status'); module_load_include('translation.inc', 'locale'); $pro

locale_translation_get_projects

locale_translation_get_projects(array $project_names = array()) Get array of projects which are available for interface translation. This project data contains all projects which will be checked for available interface translations. For full functionality this function depends on Update module. When Update module is enabled the project data will contain the most recent module status; both in enabled status as in version. When Update module is disabled this function will return the last known mo

locale_translation_get_file_history

locale_translation_get_file_history() Gets current translation status from the {locale_file} table. Return value array Array of translation file objects. File core/modules/locale/locale.module, line 816 Enables the translation of the user interface to languages other than English. Code function locale_translation_get_file_history() { $history = &drupal_static(__FUNCTION__, array()); if (empty($history)) { // Get file history from the database. $result = db_query('SELECT proj

locale_translation_flush_projects

locale_translation_flush_projects() Clear the project data table. File core/modules/locale/locale.compare.inc, line 20 The API for comparing project translation status with available translation. Code function locale_translation_flush_projects() { \Drupal::service('locale.project')->deleteAll(); }