mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-12-22 06:30:59 +01:00
fix for imap_rfc822_write_address from imap extension
This commit is contained in:
parent
e5e330034f
commit
d2eee09ff2
@ -1487,7 +1487,9 @@ class addressbook_bo extends addressbook_so
|
||||
// make sure to return a correctly quoted rfc822 address, if requested
|
||||
if ($options['type'] === 'email')
|
||||
{
|
||||
$result[$contact['id']] = imap_rfc822_write_address($contact['email'], '', $result[$contact['id']]);
|
||||
$args = explode('@', $contact['email']);
|
||||
$args[] = $result[$contact['id']];
|
||||
$result[$contact['id']] = call_user_func_array('imap_rfc822_write_address', $args);
|
||||
}
|
||||
// show category color
|
||||
if ($contact['cat_id'] && ($color = etemplate::cats2color($contact['cat_id'])))
|
||||
|
@ -3314,7 +3314,9 @@ class mail_compose
|
||||
{
|
||||
$contact['n_fn'] = str_replace(array(',','@'),' ',$contact['n_fn']);
|
||||
}
|
||||
$completeMailString = imap_rfc822_write_address(trim($email), '', trim($contact['n_fn'] ? $contact['n_fn'] : $contact['fn']));
|
||||
$args = explode('@', trim($email));
|
||||
$args[] = trim($contact['n_fn'] ? $contact['n_fn'] : $contact['fn']);
|
||||
$completeMailString = call_user_func_array('imap_rfc822_write_address', $args);
|
||||
if(!empty($email) && in_array($completeMailString ,$results) === false) {
|
||||
$results[] = array(
|
||||
'id'=>$completeMailString,
|
||||
@ -3335,7 +3337,9 @@ class mail_compose
|
||||
{
|
||||
$group = $GLOBALS['egw']->accounts->read($g_id);
|
||||
if(!$group['account_email']) continue;
|
||||
$completeMailString = imap_rfc822_write_address(trim($group['account_email']), '', $name);
|
||||
$args = explode('@', trim($group['account_email']));
|
||||
$args[] = $name;
|
||||
$completeMailString = call_user_func_array('imap_rfc822_write_address', $args);
|
||||
$results[] = array(
|
||||
'id' => $completeMailString,
|
||||
'label' => $completeMailString,
|
||||
|
Loading…
Reference in New Issue
Block a user