_locale_refresh_translations

_locale_refresh_translations($langcodes, $lids = array()) Refresh related information after string translations have been updated. The information that will be refreshed includes: JavaScript translations. Locale cache. Render cache. Parameters array $langcodes: Language codes for updated translations. array $lids: (optional) List of string identifiers that have been updated / created. If not provided, all caches for the affected languages are cleared. File core/modules/locale/locale.module,

_locale_refresh_configuration

_locale_refresh_configuration(array $langcodes, array $lids) Refreshes configuration after string translations have been updated. Parameters array $langcodes: Language codes for updated translations. array $lids: List of string identifiers that have been updated / created. File core/modules/locale/locale.module, line 1101 Enables the translation of the user interface to languages other than English. Code function _locale_refresh_configuration(array $langcodes, array $lids) { if ($lids &

_locale_rebuild_js

_locale_rebuild_js($langcode = NULL) (Re-)Creates the JavaScript translation file for a language. Parameters $langcode: The language, the translation file should be (re)created for. Return value bool TRUE if translation file exists, FALSE otherwise. File core/modules/locale/locale.module, line 1265 Enables the translation of the user interface to languages other than English. Code function _locale_rebuild_js($langcode = NULL) { $config = \Drupal::config('locale.settings'); if (!isset($l

_locale_parse_js_file

_locale_parse_js_file($filepath) Parses a JavaScript file, extracts strings wrapped in Drupal.t() and Drupal.formatPlural() and inserts them into the database. Parameters string $filepath: File name to parse. Return value array Array of string objects to update indexed by context and source. Throws Exception If a non-local file is attempted to be parsed. File core/modules/locale/locale.module, line 1133 Enables the translation of the user interface to languages other than English. Code fun

_locale_invalidate_js

_locale_invalidate_js($langcode = NULL) Force the JavaScript translation file(s) to be refreshed. This function sets a refresh flag for a specified language, or all languages except English, if none specified. JavaScript translation files are rebuilt (with locale_update_js_files()) the next time a request is served in that language. Parameters $langcode: The language code for which the file needs to be refreshed. Return value New content of the 'system.javascript_parsed' variable. File core/m

_install_select_profile

_install_select_profile(&$install_state) Determines the installation profile to use in the installer. A profile will be selected in the following order of conditions: Only one profile is available. A specific profile name is requested in installation parameters: For interactive installations via request query parameters. For non-interactive installations via install_drupal() settings. A discovered profile that is a distribution. If multiple profiles are distributions, then the first discov

_install_prepare_import

_install_prepare_import($langcodes, $server_pattern) Tells the translation import process that Drupal core is installed. Parameters array $langcodes: Language codes used for the translations. string $server_pattern: Server access pattern (to replace language code, version number, etc. in). File core/includes/install.core.inc, line 1667 API functions for installing Drupal. Code function _install_prepare_import($langcodes, $server_pattern) { \Drupal::moduleHandler()->loadInclude('locale',

_install_module_batch

_install_module_batch($module, $module_name, &$context) Implements callback_batch_operation(). Performs batch installation of modules. File core/includes/install.core.inc, line 1782 API functions for installing Drupal. Code function _install_module_batch($module, $module_name, &$context) { \Drupal::service('module_installer')->install(array($module), FALSE); $context['results'][] = $module; $context['message'] = t('Installed %module module.', array('%module' => $module_nam

_install_get_version_info

_install_get_version_info($version) Extracts version information from a drupal core version string. Parameters string $version: Version info string (e.g., 8.0.0, 8.1.0, 8.0.0-dev, 8.0.0-unstable1, 8.0.0-alpha2, 8.0.0-beta3, and 8.0.0-rc4). Return value array Associative array of version info: major: Major version (e.g., "8"). minor: Minor version (e.g., "0"). patch: Patch version (e.g., "0"). extra: Extra version info (e.g., "alpha2"). extra_text: The text part of "extra" (e.g., "alpha")

_filter_url_trim

_filter_url_trim($text, $length = NULL) Shortens long URLs to http://www.example.com/long/url… Related topics Standard filters Filters implemented by the Filter module. File core/modules/filter/filter.module, line 675 Framework for handling the filtering of content. Code function _filter_url_trim($text, $length = NULL) { static $_length; if ($length !== NULL) { $_length = $length; } if (isset($_length)) { $text = Unicode::truncate($text, $_length, FALSE, TRUE); } retur