- added patch from srakhada that uses quotemeta() function around password to allow
[squirrelmail.git] / functions / imap_mailbox.php
index 48bd446cfba7ccfea71fbd955a80cf63562aa8fb..0d966cd789d831edd0215f338855563cdebe668c 100755 (executable)
       }
       return $boxes;
    }
+
+       /* patch from dave_michmerhuizen@yahoo.com
+        * allows case insensativity when sorting folders
+        */
+       function _icmp ($a, $b) {
+               return strcasecmp($a, $b);
+       }
    
    /******************************************************************************
     **  Returns sorted mailbox lists in several different ways.
       }
       $sorted_lsub_ary = $new_ary;
       if (isset($sorted_lsub_ary)) {
-         sort($sorted_lsub_ary);
+                       usort($sorted_lsub_ary, "_icmp");
+         //sort($sorted_lsub_ary);
       }   
 
       /** LIST array **/