- added a view header option
[squirrelmail.git] / src / folders.php
index 1a86bd7513c8a1b50eed2fdb37cac882d07cf0f7..ce164ae0b16017ba6a34afd7434b7cc029324f14 100644 (file)
@@ -1,4 +1,15 @@
 <?php
+   /**
+    **  folders.php
+    **
+    **  Copyright (c) 1999-2000 The SquirrelMail development team
+    **  Licensed under the GNU GPL. For full terms see the file COPYING.
+    **
+    **  Handles all interaction between the user and the other folder
+    **  scripts which do most of the work. Also handles the Special
+    **  Folders.
+    **/
+
    session_start();
 
    if (!isset($config_php))
@@ -14,8 +25,6 @@
 
    include("../src/load_prefs.php");
 
-   echo "<HTML><BODY TEXT=\"$color[8]\" BGCOLOR=\"$color[4]\" LINK=\"$color[7]\" VLINK=\"$color[7]\" ALINK=\"$color[7]\">\n";
-
    displayPageHeader($color, "None");
 
    echo "<TABLE WIDTH=100% COLS=1 ALIGN=CENTER>\n";
                $num_max++;
 
    for ($p = 0; $p < count($boxes) && $count_special_folders < $num_max; $p++) {
-      if (strtolower($boxes[$i]["unformatted"]) == "inbox")
+      if (strtolower($boxes[$p]["unformatted"]) == "inbox")
          $count_special_folders++;
-      else if ($boxes[$i]["unformatted"] == $trash_folder)
+      else if ($boxes[$p]["unformatted"] == $trash_folder && $trash_folder)
          $count_special_folders++;
-      else if ($boxes[$i]["unformatted"] == $sent_folder)
+      else if ($boxes[$p]["unformatted"] == $sent_folder && $sent_folder)
          $count_special_folders++;
    }