Fix missing localization of HTML editor when assets_dir != INSTALL_PATH

Conflicts:
	CHANGELOG
pull/6833/head
Aleksander Machniak 10 years ago
parent 72a09408e9
commit fbf89913a3

@ -3,6 +3,7 @@ CHANGELOG Roundcube Webmail
- Searching in both contacts and groups when LDAP addressbook with group_filters option is used
- Use contact_search_name format in popup on results in compose contacts search
- Fix missing localization of HTML editor when assets_dir != INSTALL_PATH
- Fix message list multi-select/deselect issue (#5219)
- Fix bug where contact search menu fields where always unchecked in Larry skin
- Fix XSS issue in href attribute on area tag (#5240)

@ -1867,13 +1867,14 @@ class rcmail extends rcube
}
$lang_codes = array($_SESSION['language']);
$assets_dir = $this->config->get('assets_dir') ?: INSTALL_PATH;
if ($pos = strpos($_SESSION['language'], '_')) {
$lang_codes[] = substr($_SESSION['language'], 0, $pos);
}
foreach ($lang_codes as $code) {
if (file_exists(INSTALL_PATH . 'program/js/tinymce/langs/'.$code.'.js')) {
if (file_exists("$assets_dir/program/js/tinymce/langs/$code.js")) {
$lang = $code;
break;
}

Loading…
Cancel
Save