Since we're requiring PHP >= 4.0.4, we can just use move_upload_file
[squirrelmail.git] / src / search.php
index b21abf4ab1e13ebdc0e180ff8ffbebe333875df2..dcd7b285339112c51cf2edacb0508c2f66189415 100644 (file)
@@ -3,7 +3,7 @@
 /**
  * search.php
  *
- * Copyright (c) 1999-2002 The SquirrelMail Project Team
+ * Copyright (c) 1999-2003 The SquirrelMail Project Team
  * Licensed under the GNU GPL. For full terms see the file COPYING.
  *
  * $Id$
@@ -17,7 +17,6 @@ require_once(SM_PATH . 'include/validate.php');
 require_once(SM_PATH . 'functions/imap.php');
 require_once(SM_PATH . 'functions/imap_search.php');
 require_once(SM_PATH . 'functions/imap_mailbox.php');
-require_once(SM_PATH . 'functions/array.php');
 require_once(SM_PATH . 'functions/strings.php');
 
 global $allow_thread_sort;
@@ -192,8 +191,8 @@ function save_recent($save_index, $username, $data_dir) {
 function printSearchMessages($msgs,$mailbox, $cnt, $imapConnection, $where, $what, $usecache = false, $newsort = false) {
     global $sort, $color;
     
-    $msort = calc_msort($msgs, $sort);
-    if ($cnt > 0) {
+       if ($cnt > 0) {
+          $msort = calc_msort($msgs, $sort);
        if ( $mailbox == 'INBOX' ) {
            $showbox = _("INBOX");
        } else {
@@ -441,7 +440,7 @@ echo html_tag( 'div', '<b>' . _("Current Search") . '</b>', 'left' ) . "\n"
    if ($mailbox == 'All Folders') {
        echo ' selected';
    }
-   echo ">[ All Folders ]</option>\n";
+   echo '>[ ' . _("All Folders") . " ]</option>\n";
 
    $show_selected = array(strtolower($mailbox));
    echo sqimap_mailbox_option_list($imapConnection, $show_selected, 0, $boxes);
@@ -496,7 +495,7 @@ if ($search_all == 'all') {
     $boxcount = count($boxes);
     echo '<BR><CENTER><B>' .
          _("Search Results") .
-         "</B><CENTER><BR>\n";
+         "</B></CENTER><BR>\n";
     for ($x=0;$x<$boxcount;$x++) {
         if (!in_array('noselect', $boxes[$x]['flags'])) {
             $mailbox = $boxes[$x]['unformatted'];