From a97cf3d0875a23ab5e05aee1f7b13793d4f7a4a0 Mon Sep 17 00:00:00 2001 From: Michael M Slusarz Date: Thu, 5 Feb 2009 22:55:29 -0700 Subject: [PATCH] Request #5836: Decode IDN (RFC 3490) names in addresses. --- imp/docs/CHANGES | 1 + imp/docs/INSTALL | 2 +- imp/lib/Compose.php | 4 ++-- imp/message-mimp.php | 2 +- imp/message.php | 2 +- 5 files changed, 6 insertions(+), 5 deletions(-) diff --git a/imp/docs/CHANGES b/imp/docs/CHANGES index 331c9f2bc..0bf7a6cdc 100644 --- a/imp/docs/CHANGES +++ b/imp/docs/CHANGES @@ -2,6 +2,7 @@ v5.0-git -------- +[mms] Decode IDN (RFC 3490) names in addresses (Request #5836). [mms] Add ability to download attachments in MIMP (Request #2925). [mms] Revamp JS event handling model. [mms] ESC in DIMP search box now clears the search (Request #7196). diff --git a/imp/docs/INSTALL b/imp/docs/INSTALL index 9cacb5ee2..897a5a372 100644 --- a/imp/docs/INSTALL +++ b/imp/docs/INSTALL @@ -186,7 +186,7 @@ To function properly, IMP **requires** the following: a. idn [OPTIONAL] - idn is required in order to handle Internationalized Domain Names + idn is required to handle display of Internationalized Domain Names (see RFC 3490). 5. At least one IMAP or POP3 server. diff --git a/imp/lib/Compose.php b/imp/lib/Compose.php index 4ca5e3dc2..4658da5c4 100644 --- a/imp/lib/Compose.php +++ b/imp/lib/Compose.php @@ -1206,7 +1206,7 @@ class IMP_Compose foreach (array('reply-to', 'from', 'to', 'cc') as $val) { $ob = $h->getOb($val); if (!empty($ob)) { - $addr_obs = Horde_Mime_Address::getAddressesFromObject($ob, $all_addrs); + $addr_obs = Horde_Mime_Address::getAddressesFromObject($ob, array('filter' => $all_addrs)); if (!empty($addr_obs)) { if (isset($addr_obs[0]['groupname'])) { $cc_addrs = array_merge($cc_addrs, $addr_obs); @@ -1239,7 +1239,7 @@ class IMP_Compose $header[empty($header['to']) ? 'to' : 'cc'] = rtrim(implode('', $hdr_cc), ' ,'); /* Build the Bcc: header. */ - $header['bcc'] = Horde_Mime_Address::addrArray2String($h->getOb('bcc') + $identity->getBccAddresses(), $all_addrs); + $header['bcc'] = Horde_Mime_Address::addrArray2String($h->getOb('bcc') + $identity->getBccAddresses(), array('filter' => $all_addrs)); if ($actionID == '*') { $all_headers['reply_all'] = $header; } diff --git a/imp/message-mimp.php b/imp/message-mimp.php index 5ba7a71bd..349a87a27 100644 --- a/imp/message-mimp.php +++ b/imp/message-mimp.php @@ -324,7 +324,7 @@ if (empty($conf['hooks']['disable_compose']) || $items[IMP::composeLink(array(), array('a' => 'rl') + $compose_params)] = _("Reply to List"); } - if (Horde_Mime_Address::addrArray2String(array_merge($envelope['to'], $envelope['cc']), array_keys($user_identity->getAllFromAddresses(true)))) { + if (Horde_Mime_Address::addrArray2String(array_merge($envelope['to'], $envelope['cc']), array('filter' => array_keys($user_identity->getAllFromAddresses(true))))) { $items[IMP::composeLink(array(), array('a' => 'ra') + $compose_params)] = _("Reply All"); } diff --git a/imp/message.php b/imp/message.php index 57a7428e3..eb46bbf2f 100644 --- a/imp/message.php +++ b/imp/message.php @@ -500,7 +500,7 @@ if (!IMP::$printMode) { $a_template->set('reply_list', Horde::widget(IMP::composeLink(array(), array('actionID' => 'reply_list') + $compose_params), _("To List"), 'widget', '', '', _("To _List"), true)); } - if (Horde_Mime_Address::addrArray2String(array_merge($envelope['to'], $envelope['cc']), array_keys($user_identity->getAllFromAddresses(true)))) { + if (Horde_Mime_Address::addrArray2String(array_merge($envelope['to'], $envelope['cc']), array('filter' => array_keys($user_identity->getAllFromAddresses(true))))) { $a_template->set('show_reply_all', Horde::widget(IMP::composeLink(array(), array('actionID' => 'reply_all') + $compose_params), _("To All"), 'widget', '', '', _("To _All"), true)); } -- 2.11.0