added patch from tcabot for a pure HTML method of selecting all messages
authorlkehresman <lkehresman@7612ce4b-ef26-0410-bec9-ea0150e637f0>
Tue, 5 Dec 2000 16:12:32 +0000 (16:12 +0000)
committerlkehresman <lkehresman@7612ce4b-ef26-0410-bec9-ea0150e637f0>
Tue, 5 Dec 2000 16:12:32 +0000 (16:12 +0000)
in your current folder.  Works wonderfully as far as I can tell.

git-svn-id: https://svn.code.sf.net/p/squirrelmail/code/trunk/squirrelmail@860 7612ce4b-ef26-0410-bec9-ea0150e637f0

ChangeLog
functions/mailbox_display.php
src/compose.php
src/folders_create.php

index 5823fc580810865f7fce73cdd51c27d16d05bcb9..5d9dddbfae63cf27ae8b6d38a08ecc07daa8cb4c 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,6 @@
 Version 1.0pre1 -- DEVELOPMENT
 ------------------------------
+- Fixed default charset that is sent with outbound messages (now user's preferred charset)
 - Sort method saving now transparent to user, and saves between sessions
 - Now replacing all \n with \r\n before sending the message.
 - Added sorting option for NO sorting.. 10000 times faster!
index 5503e7b1cfa7ccd9c11bb8a6bbc6b0fd1b2f8218..baa59f69e5f34f366acdbb19b93e88f41ccdbd00 100644 (file)
@@ -11,6 +11,7 @@
    $mailbox_display_php = true;
 
    function printMessageInfo($imapConnection, $t, $i, $key, $mailbox, $sort, $startMessage, $where, $what) {
+      global $checkall;
       global $color, $msgs, $msort;
       global $sent_folder;
       global $message_highlight_list;
       if ($where && $what) {
          $search_stuff = "&where=".urlencode($where)."&what=".urlencode($what);
       }
+
+               if ($checkall == 1) 
+                       $checked = " checked";
+               else
+                       $checked = "";
       
       for ($i=1; $i <= count($index_order); $i++) {
          switch ($index_order[$i]) {
 
       mail_message_listing_beginning($imapConnection,
          "move_messages.php?msg=$msg&mailbox=$urlMailbox&startMessage=$startMessage",
-          $mailbox, $sort, $Message, $More);
+          $mailbox, $sort, $Message, $More, $startMessage);
 
       $groupNum = $startMessage % ($show_num - 1);
       $real_startMessage = $startMessage;
 
       echo "</td></tr>\n";
 
-      if ($More)
-      {
-         echo "<TR BGCOLOR=\"$color[4]\"><TD>$More</td></tr>\n";
-      }
+      echo "<TR BGCOLOR=\"$color[4]\"><TD>";
+               echo "<table width=100% cellpadding=0 cellspacing=0 border=0><tr><td>";
+               echo "$More</td><td align=right>\n";
+               if (!$startMessage) $startMessage=1;
+      if ( $checkall == "1")
+         echo "\n<A HREF=\"right_main.php?mailbox=$mailbox&startMessage=$startMessage&sort=$sort\">" . _("Unselect All") . "</A>\n";
+      else
+         echo "\n<A HREF=\"right_main.php?mailbox=$mailbox&startMessage=$startMessage&sort=$sort&checkall=1\">" . _("Select All") . "</A>\n";
+
+               echo "</td></tr></table>";
+               echo "</td></tr>";
       echo "</table>"; /** End of message-list table */
 
       do_hook("mailbox_index_after");
     * $More is a second line that is left aligned
     */
    function mail_message_listing_beginning($imapConnection, $moveURL,
-       $mailbox = '', $sort = -1, $Message = '', $More = '')
+       $mailbox = '', $sort = -1, $Message = '', $More = '', $startmessage = 1)
    {
       global $color, $index_order, $auto_expunge, $move_to_trash;
+               global $checkall;
                $urlMailbox = urlencode($mailbox);
 
          /** This is the beginning of the message list table.  It wraps around all messages */
          echo "<TR BGCOLOR=\"$color[4]\"><TD align=center>$Message</td></tr>\n";
       }
 
-      if ($More)
-      {
-         echo "<TR BGCOLOR=\"$color[4]\"><TD>$More</td></tr>\n";
-      }
+      echo "<TR BGCOLOR=\"$color[4]\"><TD>";
+               echo "<table width=100% cellpadding=0 cellspacing=0 border=0><tr><td>";
+               echo "$More</td><td align=right>\n";
+               if (!$startMessage) $startMessage=1;
+      if ( $checkall == "1")
+         echo "\n<A HREF=\"right_main.php?mailbox=$mailbox&startMessage=$startMessage&sort=$sort\">" . _("Unselect All") . "</A>\n";
+      else
+         echo "\n<A HREF=\"right_main.php?mailbox=$mailbox&startMessage=$startMessage&sort=$sort&checkall=1\">" . _("Select All") . "</A>\n";
+
+               echo "</td></tr></table>";
+               echo "</td></tr>";
 
       /** The delete and move options */
       echo "<TR><TD BGCOLOR=\"$color[0]\">";
       echo "<TABLE BGCOLOR=\"$color[0]\" COLS=2 BORDER=0 cellpadding=0 cellspacing=0 width=100%>\n";
       echo "   <TR>\n";
       echo "      <TD WIDTH=60% ALIGN=LEFT VALIGN=CENTER>\n";
+
+
       echo "         <NOBR><SMALL>". _("Move selected to:") ."</SMALL>";
       echo "         <TT><SMALL><SELECT NAME=\"targetMailbox\">";
 
index a8d4045e322ebec342f6a6d798f010843be8f2a6..91d1641492bc5eb37c4b217402db52de5d96c2af 100644 (file)
       }
 
       showInputForm();
+       } else if ($smtpErrors) {
+      $imapConnection = sqimap_login($username, $key, $imapServerAddress, $imapPort, 0);
+      displayPageHeader($color, $mailbox);
+
+      $newmail = true;
+      if ($forward_id && $ent_num)  getAttachments(0);
+              
+      newMail();
+      showInputForm();
+      sqimap_logout($imapConnection);
    } else {
       $imapConnection = sqimap_login($username, $key, $imapServerAddress, $imapPort, 0);
       displayPageHeader($color, $mailbox);
 
       $newmail = true;
+               
       if ($forward_id && $ent_num)  getAttachments(0);
               
       newMail();
index 7d090337a16c13fae7c8c10b7206815a4278a07f..1db6920970d851461f58d1445d201529344b116c 100644 (file)
@@ -29,6 +29,7 @@
 
    if (strpos($folder_name, "\"") || strpos($folder_name, "\\") ||
        strpos($folder_name, "'") || strpos($folder_name, "$dm")) {
+               print "<html><body bgcolor=$color[4]>";
       plain_error_message(_("Illegal folder name.  Please select a different name.")."<BR><A HREF=\"../src/folders.php\">"._("Click here to go back")."</A>.", $color);
       sqimap_logout($imapConnection);
       exit;