From a48fbf9b8db674a9bf4361d6f8c64e402cb6445a Mon Sep 17 00:00:00 2001 From: lkehresman Date: Mon, 31 Jul 2000 10:08:46 +0000 Subject: [PATCH] added a bunch of patches from the patch manager git-svn-id: https://svn.code.sf.net/p/squirrelmail/code/trunk/squirrelmail@654 7612ce4b-ef26-0410-bec9-ea0150e637f0 --- doc/README.russian_apache | 6 ++++++ src/compose.php | 1 + src/delete_message.php | 2 ++ src/download.php | 8 +++----- src/read_body.php | 2 +- src/right_main.php | 7 +------ 6 files changed, 14 insertions(+), 12 deletions(-) diff --git a/doc/README.russian_apache b/doc/README.russian_apache index 7b7fd7d5..89a2b515 100644 --- a/doc/README.russian_apache +++ b/doc/README.russian_apache @@ -4,6 +4,12 @@ HOW TO CONFIGURE SQUIRREL-MAIL WITH RUSSIAN APACHE This text is available in Russian at http://www.mricon.com/SM/russian_apache.html +***** +NOTE: Russian Apache will recode all attachments, even if they +are binary, thus corrupting them. To fix this problem, refer to +Russian Apache FAQ: http://apache.lexa.ru/faq.html#5 +***** + This howto is for people who are using Russian Apache and who use charsets other than koi8-r for their source documents. If you _do_ use KOI8-R as default encoding for all your source diff --git a/src/compose.php b/src/compose.php index 5617da79..9c8acbaa 100644 --- a/src/compose.php +++ b/src/compose.php @@ -104,6 +104,7 @@ /** This formats a CC string if they hit "reply all" **/ if ($send_to_cc != "") { + $send_to_cc = ereg_replace( '"[^"]*"', "", $send_to_cc); $send_to_cc = ereg_replace(";", ",", $send_to_cc); $sendcc = explode(",", $send_to_cc); $send_to_cc = ""; diff --git a/src/delete_message.php b/src/delete_message.php index 3f281397..f485b387 100644 --- a/src/delete_message.php +++ b/src/delete_message.php @@ -36,4 +36,6 @@ header ("Location: $location/search.php?where=".urlencode($where)."&what=".urlencode($what)."&mailbox=".urlencode($mailbox)); else header ("Location: $location/right_main.php?sort=$sort&startMessage=$startMessage&mailbox=".urlencode($mailbox)); + + sqimap_logout($imapConnection); ?> diff --git a/src/download.php b/src/download.php index 9f60f343..ef6df67e 100644 --- a/src/download.php +++ b/src/download.php @@ -9,8 +9,6 @@ ** Also allows displaying of attachments when possible. **/ - session_start(); - if (!isset($config_php)) include("../config/config.php"); if (!isset($strings_php)) @@ -101,8 +99,8 @@ switch($type0) { case "text": $body = decodeBody($body, $header->encoding); - header("Content-type: application/octet-stream; name=\"$filename\""); header("Content-Disposition: attachment; filename=\"$filename\""); + header("Content-type: application/octet-stream; name=\"$filename\""); if ($type1 == "plain") { echo _("Subject") . ": " . decodeHeader(stripslashes($top_header->subject)) . "\n"; echo " " . _("From") . ": " . decodeHeader(stripslashes($top_header->from)) . "\n"; @@ -113,8 +111,8 @@ break; default: $body = decodeBody($body, $header->encoding); - header("Content-type: application/octet-stream; name=\"$filename\""); header("Content-Disposition: attachment; filename=\"$filename\""); + header("Content-type: application/octet-stream; name=\"$filename\""); echo $body; break; } @@ -130,8 +128,8 @@ break; default: $body = decodeBody($body, $header->encoding); - header("Content-type: $type0/$type1; name=\"$filename\""); header("Content-Disposition: attachment; filename=\"$filename\""); + header("Content-type: $type0/$type1; name=\"$filename\""); echo $body; break; } diff --git a/src/read_body.php b/src/read_body.php index 59e6f0d3..573869a1 100644 --- a/src/read_body.php +++ b/src/read_body.php @@ -314,7 +314,7 @@ echo ""; echo " "; echo ""; - echo "\n"; + echo "
\n"; echo "
\n"; $body = formatBody($imapConnection, $message, $color, $wrap_at); diff --git a/src/right_main.php b/src/right_main.php index 619aa938..c1f96f84 100644 --- a/src/right_main.php +++ b/src/right_main.php @@ -64,16 +64,11 @@ include("../src/load_prefs.php"); // If the page has been loaded without a specific mailbox, - // just show a page of general info. + // send them to the inbox if (!isset($mailbox)) { $mailbox = "INBOX"; $sort = $newsort = 0; $startMessage = 1; - -// displayPageHeader($color, "None"); -// general_info($motd, $org_logo, $version, $org_name, $color); -// echo ""; -// exit; } sqimap_mailbox_select($imapConnection, $mailbox); -- 2.25.1