fixed some html errors, added endlines
authorlkehresman <lkehresman@7612ce4b-ef26-0410-bec9-ea0150e637f0>
Wed, 9 Aug 2000 15:17:44 +0000 (15:17 +0000)
committerlkehresman <lkehresman@7612ce4b-ef26-0410-bec9-ea0150e637f0>
Wed, 9 Aug 2000 15:17:44 +0000 (15:17 +0000)
git-svn-id: https://svn.code.sf.net/p/squirrelmail/code/trunk/squirrelmail@687 7612ce4b-ef26-0410-bec9-ea0150e637f0

functions/imap_general.php
functions/imap_mailbox.php
functions/mime.php
functions/page_header.php
src/compose.php
src/help.php
src/left_main.php
src/right_main.php

index 81426ac..67fe8b7 100755 (executable)
 
       if ($handle_errors == true) {
          if ($response == "NO") {
-            echo "<br><b><font color=$color[2]>";
+            echo "<br><b><font color=$color[2]>\n";
             echo _("ERROR : Could not complete request.");
-            echo "</b><br>";
+            echo "</b><br>\n";
             echo _("Reason Given: ");
-            echo "$message</font><br>";
+            echo "$message</font><br>\n";
             exit;
          } else if ($response == "BAD") {
-            echo "<br><b><font color=$color[2]>";
+            echo "<br><b><font color=$color[2]>\n";
             echo _("ERROR : Bad or malformed request.");
-            echo "</b><br>";
+            echo "</b><br>\n";
             echo _("Server responded: ");
-            echo "$message</font><br>";
+            echo "$message</font><br>\n";
             exit;
          }
       }
index 66f6dda..ee858ed 100755 (executable)
    /******************************************************************************
     **  Selects a mailbox
     ******************************************************************************/
-   function sqimap_mailbox_select ($imap_stream, $mailbox, $hide=true) {
+   function sqimap_mailbox_select ($imap_stream, $mailbox, $hide=true, $recent=false) {
       fputs ($imap_stream, "a001 SELECT \"$mailbox\"\r\n");
        $read = sqimap_read_data($imap_stream, "a001", true, $response, $message);
+      if ($recent) {
+         for ($i=0; $i<count($read); $i++) {
+            if (strpos(strtolower($read[$i]), "recent")) {
+               $r = explode(" ", $read[$i]);
+            }
+         }
+         return $r[1];
+      }
    }
 
    
index 3bc9b56..3bae25a 100644 (file)
@@ -68,7 +68,7 @@
    //   $read = strtolower($bodystructure);
       $read = $bodystructure;
 
-      if ($debug_mime) echo "<tt>$read</tt><br><br>";
+      if ($debug_mime) echo "<tt>$read</tt><br><br>\n";
       // isolate the body structure and remove beginning and end parenthesis
       $read = trim(substr ($read, strpos(strtolower($read), "bodystructure") + 13));
       $read = trim(substr ($read, 0, -1));
@@ -79,7 +79,7 @@
          $end = mime_match_parenthesis(0, $read);
       }
 
-      if ($debug_mime) echo "<tt>$read</tt><br><br>";
+      if ($debug_mime) echo "<tt>$read</tt><br><br>\n";
 
       $msg = mime_parse_structure ($read, 0);
       $msg->header = $header;
@@ -95,7 +95,7 @@
    // to mime_get_elements()
    function mime_parse_structure ($structure, $ent_id) {
       global $debug_mime;
-      if ($debug_mime) echo "<font color=008800><tt>START: mime_parse_structure()</tt></font><br>";
+      if ($debug_mime) echo "<font color=008800><tt>START: mime_parse_structure()</tt></font><br>\n";
       $msg = new message();
       if (substr($structure, 0, 1) == "(") {
          $ent_id = mime_new_element_level($ent_id);
index ee5c665..22a8e0b 100644 (file)
@@ -53,7 +53,7 @@
       
       do_hook ("generic_header");
 
-      echo "<TITLE>$title</TITLE>";
+      echo "<TITLE>$title</TITLE>\n";
       echo "</HEAD>\n\n";
    }
 
index a1e43f7..e403961 100644 (file)
          echo "// --></SCRIPT>\n\n";
       }
 
-      echo "\n<FORM name=compose action=\"compose.php\" METHOD=POST ENCTYPE=\"multipart/form-data\">\n";
-      //echo "\n<FORM name=compose action=\"compose.php\" METHOD=POST>\n";
+      //echo "\n<FORM name=compose action=\"compose.php\" METHOD=POST ENCTYPE=\"multipart/form-data\">\n";
+      echo "\n<FORM name=compose action=\"compose.php\" METHOD=POST>\n";
       if ($reply_id) {
          echo "<input type=hidden name=reply_id value=$reply_id>\n";
       }                 
index 3ef81b7..884b8fd 100644 (file)
          else echo "<a href=\"../src/help.php?chapter=".($chapter-1)."\">Previous</a> | ";
          echo "<a href=\"../src/help.php\">Table of Contents</a>";
          if ($chapter >= count($helpdir)) echo " | <font color=\"$color[9]\">Next</font>";
-         else echo " | <a href=\"../src/help.php?chapter=".($chapter+1)."\">Next</a>";
+         else echo " | <a href=\"../src/help.php?chapter=".($chapter+1)."\">Next</a>\n";
          echo "</center></small><br>\n";
 
          echo "<font size=5><b>$chapter - $help_info[0]</b></font><br><br>\n";
          if ($help_info[1])
-            echo "$help_info[1]";
+            echo "$help_info[1]\n";
          else   
-            echo "<p>$help_info[2]</p>";
+            echo "<p>$help_info[2]</p>\n";
 
          for ($n = $help_info[3]; $n < count($doc); $n++) {
             $section++;
             $n = $help_info[3];
          }
 
-         echo "<br><center><a href=\"#pagetop\">" . _("Top") . "</a></center>";
+         echo "<br><center><a href=\"#pagetop\">" . _("Top") . "</a></center>\n";
       }
    }
    do_hook("help_bottom"); 
index d6de4f8..39382ea 100644 (file)
@@ -40,6 +40,7 @@
 
    displayHtmlHeader();
 
+
    function formatMailboxName($imapConnection, $mailbox, $real_box, $delimeter, $unseen) {
                global $folder_prefix, $trash_folder, $sent_folder;
                global $color, $move_to_sent, $move_to_trash;
       echo "<META HTTP-EQUIV=\"REFRESH\" CONTENT=\"$left_refresh;URL=left_main.php\">\n";
    }
    
-   echo "\n<BODY BGCOLOR=\"$color[3]\" TEXT=\"$color[6]\" LINK=\"$color[6]\" VLINK=\"$color[6]\" ALINK=\"$color[6]\">\n\n";
+   echo "\n<BODY BGCOLOR=\"$color[3]\" TEXT=\"$color[6]\" LINK=\"$color[6]\" VLINK=\"$color[6]\" ALINK=\"$color[6]\">\n";
 
    do_hook("left_main_before");
 
       } else {
          $line .= formatMailboxName($imapConnection, $mailbox, $boxes[$i]["unformatted"], $delimeter, $boxes[$i]["unseen"]);
       }
-      echo "\n$line<BR>\n";
+      echo "$line<BR>\n";
    }
    sqimap_logout($imapConnection);
    do_hook("left_main_after");
index 8db65bc..1827afa 100644 (file)
    do_hook("right_main_after_header");
    
    if ($just_logged_in == 1 && strlen(trim($motd)) > 0) {
-      echo "<center><br>";
-      echo "<table width=70% cellpadding=0 cellspacing=0 border=0><tr><td bgcolor=\"$color[9]\">";
-      echo "<table width=100% cellpadding=5 cellspacing=1 border=0><tr><td bgcolor=\"$color[4]\">";
-      echo "$motd";
-      echo "</td></tr></table>";
-      echo "</td></tr></table>";
-      echo "</center><br>";
+      echo "<center><br>\n";
+      echo "<table width=70% cellpadding=0 cellspacing=0 border=0><tr><td bgcolor=\"$color[9]\">\n";
+      echo "<table width=100% cellpadding=5 cellspacing=1 border=0><tr><td bgcolor=\"$color[4]\">\n";
+      echo "$motd\n";
+      echo "</td></tr></table>\n";
+      echo "</td></tr></table>\n";
+      echo "</center><br>\n";
    }
 
        if (isset($newsort)) {