handle whitespace in emailaddresses when adding distributionlists to email-compose window

This commit is contained in:
Klaus Leithoff 2010-11-25 13:38:38 +00:00
parent b72fb5e76b
commit 4ffe2fc6e0

View File

@ -737,7 +737,9 @@ class addressbook_ui extends addressbook_bo
{
$contact['n_fn'] = str_replace(',',' ',$contact['n_fn']);
egw_framework::set_onload("addEmail('".addslashes(
$contact['n_fn'] ? $contact['n_fn'].' <'.$email.'>' : $email)."');");
$contact['n_fn'] ? $contact['n_fn'].' <'.trim($email).'>' : trim($email))."');");
//error_log(__METHOD__.__LINE__."addEmail('".addslashes(
// $contact['n_fn'] ? $contact['n_fn'].' <'.trim($email).'>' : trim($email))."');");
$Ok = true;
}
}