Don't run full address thru htmlspecialchars when it gets urlencoded anyway; compose...
authorpdontthink <pdontthink@7612ce4b-ef26-0410-bec9-ea0150e637f0>
Tue, 7 Oct 2008 08:56:21 +0000 (08:56 +0000)
committerpdontthink <pdontthink@7612ce4b-ef26-0410-bec9-ea0150e637f0>
Tue, 7 Oct 2008 08:56:21 +0000 (08:56 +0000)
git-svn-id: https://svn.code.sf.net/p/squirrelmail/code/trunk/squirrelmail@13297 7612ce4b-ef26-0410-bec9-ea0150e637f0

templates/util_addressbook.php

index 92c1b2fe031c075ab83fa9864067191d22ba8d4d..5ff5f420240ddc77792632d2ddd65e353f714078 100644 (file)
@@ -21,7 +21,7 @@
  */
 function composeLink ($row) {
     return makeComposeLink('src/compose.php?send_to=' .
-                           rawurlencode($row['FullAddress']),
+                           rawurlencode($row['RawFullAddress']),
                            htmlspecialchars($row['Email']));
 }
 
@@ -41,16 +41,17 @@ function formatAddressList ($addresses) {
     $contacts = array();
     while(list($undef,$row) = each($addresses)) {
         $contact = array (
-                            'FirstName'     => htmlspecialchars($row['firstname']),
-                            'LastName'      => htmlspecialchars($row['lastname']),
-                            'FullName'      => htmlspecialchars($row['name']),
-                            'NickName'      => htmlspecialchars($row['nickname']),
-                            'Email'         => htmlspecialchars($row['email']),
-                            'FullAddress'   => htmlspecialchars(AddressBook::full_address($row)),
-                            'Info'          => htmlspecialchars($row['label']),
-                            'Extra'         => (isset($row['extra']) ? $row['extra'] : NULL),
-                            'Source'        => htmlspecialchars($row['source']),
-                            'JSEmail'       => htmlspecialchars(addcslashes(AddressBook::full_address($row), "'"), ENT_QUOTES),
+                            'FirstName'      => htmlspecialchars($row['firstname']),
+                            'LastName'       => htmlspecialchars($row['lastname']),
+                            'FullName'       => htmlspecialchars($row['name']),
+                            'NickName'       => htmlspecialchars($row['nickname']),
+                            'Email'          => htmlspecialchars($row['email']),
+                            'FullAddress'    => htmlspecialchars(AddressBook::full_address($row)),
+                            'RawFullAddress' => AddressBook::full_address($row),
+                            'Info'           => htmlspecialchars($row['label']),
+                            'Extra'          => (isset($row['extra']) ? $row['extra'] : NULL),
+                            'Source'         => htmlspecialchars($row['source']),
+                            'JSEmail'        => htmlspecialchars(addcslashes(AddressBook::full_address($row), "'"), ENT_QUOTES),
                          );
         $contacts[] = $contact;
     }