[prev in list] [next in list] [prev in thread] [next in thread]
List: squirrelmail-cvs
Subject: [SM-CVS] SF.net SVN: squirrelmail:[13407]
From: pdontthink () users ! sourceforge ! net
Date: 2009-02-19 23:34:11
Message-ID: E1LaIPD-00026t-Ek () bj8yhf1 ! ch3 ! sourceforge ! com
[Download RAW message or body]
Revision: 13407
http://squirrelmail.svn.sourceforge.net/squirrelmail/?rev=13407&view=rev
Author: pdontthink
Date: 2009-02-19 23:34:11 +0000 (Thu, 19 Feb 2009)
Log Message:
-----------
Allow multiple addresses in one abook entry (separate with commas), although we \
HIGHLY DISCOURAGE grouping in this manner - note amongst other issues that can come \
up, sizing for large groups will be a problem
Modified Paths:
--------------
trunk/squirrelmail/functions/addressbook.php
Modified: trunk/squirrelmail/functions/addressbook.php
===================================================================
--- trunk/squirrelmail/functions/addressbook.php 2009-02-19 23:33:54 UTC (rev 13406)
+++ trunk/squirrelmail/functions/addressbook.php 2009-02-19 23:34:11 UTC (rev 13407)
@@ -516,12 +516,26 @@
function full_address($row) {
global $data_dir, $username;
$addrsrch_fullname = getPref($data_dir, $username, 'addrsrch_fullname');
- if ($addrsrch_fullname == 'fullname')
- return '"' . $row['name'] . '" <' . trim($row['email']) . '>';
- else if ($addrsrch_fullname == 'nickname')
- return '"' . $row['nickname'] . '" <' . trim($row['email']) . '>';
- else // "noprefix"
- return trim($row['email']);
+
+ // allow multiple addresses in one row (poor person's grouping - bah)
+ // (separate with commas)
+ //
+ $return = '';
+ $addresses = explode(',', $row['email']);
+ foreach ($addresses as $address) {
+
+ if (!empty($return)) $return .= ', ';
+
+ if ($addrsrch_fullname == 'fullname')
+ $return .= '"' . $row['name'] . '" <' . trim($address) . '>';
+ else if ($addrsrch_fullname == 'nickname')
+ $return .= '"' . $row['nickname'] . '" <' . trim($address) . '>';
+ else // "noprefix"
+ $return .= trim($address);
+
+ }
+
+ return $return;
}
/**
This was sent by the SourceForge.net collaborative development platform, the world's \
largest Open Source development site.
------------------------------------------------------------------------------
Open Source Business Conference (OSBC), March 24-25, 2009, San Francisco, CA
-OSBC tackles the biggest issue in open source: Open Sourcing the Enterprise
-Strategies to boost innovation and cut costs with open source participation
-Receive a $600 discount off the registration fee with the source code: SFAD
http://p.sf.net/sfu/XcvMzF8H
-----
squirrelmail-cvs mailing list
List address: squirrelmail-cvs@lists.sourceforge.net
List info (subscribe/unsubscribe/change options): \
https://lists.sourceforge.net/lists/listinfo/squirrelmail-cvs
Repository: http://squirrelmail.org/svn
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic