From aa8dcbd5f0cf3e04c6eb1f147a1fb617fcb1a924 Mon Sep 17 00:00:00 2001 From: lkehresman Date: Sat, 15 Jul 2000 12:30:20 +0000 Subject: [PATCH] fixed bug in conf.pl that didn't let you have more than 10 themes removed unnecessary condition in download.php git-svn-id: https://svn.code.sf.net/p/squirrelmail/code/trunk/squirrelmail@619 7612ce4b-ef26-0410-bec9-ea0150e637f0 --- config/conf.pl | 3 ++- src/download.php | 10 +++------- 2 files changed, 5 insertions(+), 8 deletions(-) diff --git a/config/conf.pl b/config/conf.pl index a8648ff0..8912bb39 100755 --- a/config/conf.pl +++ b/config/conf.pl @@ -50,7 +50,8 @@ while ($line = ) { } elsif ($options[0] =~ /^theme\[[0-9]+\]\["NAME"\]/) { $sub = $options[0]; $sub =~ s/\]\["NAME"\]//; - $sub = substr ($sub, @sub-1, 1); + $sub =~ s/.*\[//; + #$sub = substr ($sub, @sub-1, 1); $theme_name[$sub] = $options[1]; } elsif ($options[0] =~ /^ldap_server\[[0-9]+\]/) { $sub = $options[0]; diff --git a/src/download.php b/src/download.php index bf44bbe4..5302bfb1 100644 --- a/src/download.php +++ b/src/download.php @@ -31,7 +31,8 @@ echo "
"; echo "
"; - echo _("Viewing a plain text attachment"); + echo _("Viewing a text attachment") . " - "; + echo "". _("View message") . ""; echo "
"; echo "
"; $urlmailbox = urlencode($mailbox); @@ -113,11 +114,6 @@ echo $body; break; } -# } else if ($view == "true") { -# $body = decodeBody ($body, $header->encoding); -# header("Content-type: $type0/$type1; name=\"$filename\""); -# header("Content-disposition: attachment; filename=\"$filename\""); -# echo $body; } else { switch ($type0) { case "text": @@ -130,7 +126,7 @@ break; default: $body = decodeBody($body, $header->encoding); - header("Content-type: applicatin/octet-stream; name=\"$filename\""); + header("Content-type: $type0/$type1; name=\"$filename\""); header("Content-Disposition: attachment; filename=\"$filename\""); echo $body; break; -- 2.25.1