locale_translation_file_history_delete

locale_translation_file_history_delete($projects = array(), $langcodes = array()) Deletes the history of downloaded translations. Parameters array $projects: Project name(s) to be deleted from the file history. If both project(s) and language code(s) are specified the conditions will be ANDed. array $langcodes: Language code(s) to be deleted from the file history. File core/modules/locale/locale.module, line 866 Enables the translation of the user interface to languages other than English. C

locale_translation_download_source

locale_translation_download_source($source_file, $directory = 'temporary://') Downloads a translation file from a remote server. Parameters object $source_file: Source file object with at least: "uri": uri to download the file from. "project": Project name. "langcode": Translation language. "version": Project version. "filename": File name. string $directory: Directory where the downloaded file will be saved. Defaults to the temporary file path. Return value object File object if downl

locale_translation_default_translation_server

locale_translation_default_translation_server() Retrieve data for default server. Return value array Array of server parameters: "server_pattern": URI containing po file pattern. File core/modules/locale/locale.compare.inc, line 159 The API for comparing project translation status with available translation. Code function locale_translation_default_translation_server() { $pattern = \Drupal::config('locale.settings')->get('translation.default_server_pattern'); // An additional check

LOCALE_TRANSLATION_DEFAULT_SERVER_PATTERN

Default location of gettext file on the translation server. See also locale_translation_default_translation_server(). File core/modules/locale/locale.module, line 102 Enables the translation of the user interface to languages other than English. Code const LOCALE_TRANSLATION_DEFAULT_SERVER_PATTERN = 'http://ftp.drupal.org/files/translations/%core/%project/%project-%version.%language.po';

LOCALE_TRANSLATION_CURRENT

Translation source is the current translation. File core/modules/locale/locale.module, line 139 Enables the translation of the user interface to languages other than English. Code const LOCALE_TRANSLATION_CURRENT = 'current';

locale_translation_clear_status

locale_translation_clear_status() Clear the translation status cache. File core/modules/locale/locale.module, line 1006 Enables the translation of the user interface to languages other than English. Code function locale_translation_clear_status() { \Drupal::state()->delete('locale.translation_status'); \Drupal::state()->delete('locale.translation_last_checked'); }

locale_translation_clear_cache_projects

locale_translation_clear_cache_projects() Clears the projects cache. File core/modules/locale/locale.translation.inc, line 85 Common API for interface translation. Code function locale_translation_clear_cache_projects() { drupal_static_reset('locale_translation_get_projects'); }

locale_translation_check_projects_local

locale_translation_check_projects_local($projects = array(), $langcodes = array()) Check and store the status and timestamp of local po files. Only po files in the local file system are checked. Any remote translation files will be ignored. Projects may contain a server_pattern option containing a pattern of the path to the po source files. If no server_pattern is defined the default translation directory is checked for the po file. When a server_pattern is defined the specified location is che

locale_translation_check_projects_batch

locale_translation_check_projects_batch($projects = array(), $langcodes = array()) Gets and stores the status and timestamp of remote po files. A batch process is used to check for po files at remote locations and (when configured) to check for po files in the local file system. The most recent translation source states are stored in the state variable 'locale.translation_status'. Parameters array $projects: Array of project names to check. Defaults to all translatable projects. string $langco

locale_translation_check_projects

locale_translation_check_projects($projects = array(), $langcodes = array()) Check for the latest release of project translations. @todo Return batch or NULL. Parameters array $projects: Array of project names to check. Defaults to all translatable projects. string $langcodes: Array of language codes. Defaults to all translatable languages. Return value array Available sources indexed by project and language. File core/modules/locale/locale.compare.inc, line 184 The API for comparing project