From: Michael M Slusarz Date: Fri, 4 Dec 2009 08:05:48 +0000 (-0700) Subject: tweaks X-Git-Url: https://git.internetallee.de/?a=commitdiff_plain;h=d0d446c53d27a7adf932c216d7d1feff8ca21273;p=horde.git tweaks --- diff --git a/imp/view.php b/imp/view.php index 039de9c95..31a337a3f 100644 --- a/imp/view.php +++ b/imp/view.php @@ -1,7 +1,9 @@ * 'actionID' - (string) The action ID to perform * 'compose_attach_preview' @@ -34,8 +36,7 @@ function _sanitizeName($name) { - $name = Horde_String::convertCharset($name, Horde_Nls::getCharset(), 'UTF-8'); - return Horde_String::convertCharset(trim(preg_replace('/[^\pL\pN-+_. ]/u', '_', $name), ' _'), 'UTF-8'); + return Horde_String::convertCharset(trim(preg_replace('/[^\pL\pN-+_. ]/u', '_', Horde_String::convertCharset($name, Horde_Nls::getCharset(), 'UTF-8')), ' _'), 'UTF-8'); } require_once dirname(__FILE__) . '/lib/Application.php'; @@ -43,18 +44,17 @@ require_once dirname(__FILE__) . '/lib/Application.php'; /* Don't compress if we are already sending in compressed format. */ $actionID = Horde_Util::getFormData('actionID'); new IMP_Application(array('init' => array( - 'session_control' => 'readonly', - 'nocompress' => (($actionID == 'download_all') || Horde_Util::getFormData('zip')) + 'nocompress' => (($actionID == 'download_all') || Horde_Util::getFormData('zip')), + 'session_control' => 'readonly' ))); $ctype = Horde_Util::getFormData('ctype'); $id = Horde_Util::getFormData('id'); -/* 'compose_attach_preview' doesn't use IMP_Contents since there is no - * IMAP message data - rather, we must use the IMP_Compose object to - * get the necessary Horde_Mime_Part. */ +/* 'compose_attach_preview' doesn't use IMP_Contents since there is no mail + * message data. Rather, we must use the IMP_Compose object to get the + * necessary data for Horde_Mime_Part. */ if ($actionID == 'compose_attach_preview') { - /* Initialize the IMP_Compose:: object. */ $imp_compose = IMP_Compose::singleton(Horde_Util::getFormData('composeCache')); $mime = $imp_compose->buildAttachment($id); $mime->setMimeId($id);