Browse code

IMAP-Accounts alphabetisch sortiert ausgeben

git-svn-id: https://svn.schokokeks.org/repos/tools/webinterface/trunk@1969 87cf0b9e-d624-0410-a070-f6ee81989793

bernd authored on01/04/2011 05:51:33
Showing1 changed files
... ...
@@ -12,7 +12,7 @@ require_once('common.php');
12 12
 function mailaccounts($uid)
13 13
 {
14 14
   $uid = (int) $uid;
15
-  $result = db_query("SELECT m.id,concat_ws('@',`m`.`local`,if(isnull(`m`.`domain`),'".config('masterdomain')."',`d`.`domainname`)) AS `account`, `m`.`password` AS `cryptpass`,`m`.`maildir` AS `maildir`,aktiv from (`mail`.`mailaccounts` `m` left join `mail`.`v_domains` `d` on((`d`.`id` = `m`.`domain`))) WHERE m.uid=$uid");
15
+  $result = db_query("SELECT m.id,concat_ws('@',`m`.`local`,if(isnull(`m`.`domain`),'".config('masterdomain')."',`d`.`domainname`)) AS `account`, `m`.`password` AS `cryptpass`,`m`.`maildir` AS `maildir`,aktiv from (`mail`.`mailaccounts` `m` left join `mail`.`v_domains` `d` on((`d`.`id` = `m`.`domain`))) WHERE m.uid=$uid ORDER BY if(isnull(`m`.`domain`),'".config('masterdomain')."',`d`.`domainname`), local");
16 16
   DEBUG("Found ".@mysql_num_rows($result)." rows!");
17 17
   $accounts = array();
18 18
   if (@mysql_num_rows($result) > 0)