From: Michael M Slusarz Date: Tue, 27 Jul 2010 23:57:01 +0000 (-0600) Subject: Make sure we convert back to proper charset X-Git-Url: https://git.internetallee.de/?a=commitdiff_plain;h=9e0e56d72ee6d729daaab946885dcc127f0c2f94;p=horde.git Make sure we convert back to proper charset --- diff --git a/framework/Mime_Viewer/lib/Horde/Mime/Viewer/Html.php b/framework/Mime_Viewer/lib/Horde/Mime/Viewer/Html.php index 5cbc16bcf..d07ebb153 100644 --- a/framework/Mime_Viewer/lib/Horde/Mime/Viewer/Html.php +++ b/framework/Mime_Viewer/lib/Horde/Mime/Viewer/Html.php @@ -110,6 +110,9 @@ class Horde_Mime_Viewer_Html extends Horde_Mime_Viewer_Base { global $browser; + $charset = isset($options['charset']) + ? $options['charset'] + : $this->_mimepart->getCharset(); $strip_style_attributes = (!empty($options['inline']) && (($browser->isBrowser('mozilla') && ($browser->getMajor() == 4)) || @@ -136,7 +139,7 @@ class Horde_Mime_Viewer_Html extends Horde_Mime_Viewer_Base $this->_node($data, $data); - return $data->saveHTML(); + return Horde_String::convertCharset($data->saveHTML(), $data->encoding, $charset); } /**