getting ready for 1.2.3
[squirrelmail.git] / src / addrbook_search.php
index dbaff000dfccb656f827fde9803f5b920344c8c6..46e6cdc743cd6473ae0a565f6f44b026cb8ad367 100644 (file)
@@ -105,7 +105,7 @@ function display_result($res, $includesource = true) {
     
     while (list($undef, $row) = each($res)) {
         echo '<tr';
-        if ($line % 2) { echo ' bgcolor="' . $color[0] . '"' }
+        if ($line % 2) { echo ' bgcolor="' . $color[0] . '"'; }
         echo ' nowrap><td valign=top nowrap align=center width="5%">' .
              '<small><a href="javascript:to_address(' . 
                                        "'" . $row['email'] . "');\">To</A> | " .
@@ -205,6 +205,7 @@ if ($show == 'form') {
             $res = $abook->list_addr($backend);
 
             if(is_array($res)) {
+                usort($res,'alistcmp');
                 display_result($res, false);
             } else {
                 echo '<P ALIGN=center><STRONG>' .
@@ -214,6 +215,7 @@ if ($show == 'form') {
             }
         } else {
             $res = $abook->list_addr();
+            usort($res,'alistcmp');
             display_result($res, true);
         }