mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-11-26 18:03:39 +01:00
in case no charset is set, default to utf-8, as otherwise setting charset in sqlfs_stream_wrapper can stall install
This commit is contained in:
parent
108e95a51a
commit
f9f31ce17e
@ -134,6 +134,9 @@ class translation
|
||||
// if no translations are loaded (system-startup) use a default, else lang('charset')
|
||||
$charset = !self::$lang_arr ? 'utf-8' : strtolower(self::translate('charset'));
|
||||
}
|
||||
// in case no charset is set, default to utf-8
|
||||
if (empty($charset) || $charset == 'charset') $charset = 'utf-8';
|
||||
|
||||
// we need to set our charset as mbstring.internal_encoding if mbstring.func_overlaod > 0
|
||||
// else we get problems for a charset is different from the default utf-8
|
||||
if (ini_get('mbstring.func_overload') && self::$mbstring_internal_encoding != $charset)
|
||||
@ -1027,7 +1030,7 @@ class translation
|
||||
if ($element->charset != 'x-unknown')
|
||||
{
|
||||
if( strtoupper($element->charset) != 'UTF-8') $element->text = preg_replace($sar,$rar,$element->text);
|
||||
if(preg_match('/\?=.+=\?/', $element->text))
|
||||
if(preg_match('/\?=.+=\?/', $element->text))
|
||||
{
|
||||
$element->text = self::decodeMailHeader($element->text, $element->charset);
|
||||
$element->charset = $displayCharset;
|
||||
|
Loading…
Reference in New Issue
Block a user