fixed bug in conf.pl that didn't let you have more than 10 themes
authorlkehresman <lkehresman@7612ce4b-ef26-0410-bec9-ea0150e637f0>
Sat, 15 Jul 2000 12:30:20 +0000 (12:30 +0000)
committerlkehresman <lkehresman@7612ce4b-ef26-0410-bec9-ea0150e637f0>
Sat, 15 Jul 2000 12:30:20 +0000 (12:30 +0000)
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
src/download.php

index a8648ff02a592f41fd50007a6a6f051197e0bb8a..8912bb39fad46b46afeb62e0757c2544b617629a 100755 (executable)
@@ -50,7 +50,8 @@ while ($line = <FILE>) {
          } 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];
index bf44bbe443fc1b46005e5ff8d3984a8c5836b6df..5302bfb193bf0ff23c0587467e4c8938505cc0b6 100644 (file)
@@ -31,7 +31,8 @@
 
       echo "<BR><TABLE WIDTH=90% BORDER=0 CELLSPACING=0 CELLPADDING=2 ALIGN=CENTER><TR><TD BGCOLOR=\"$color[0]\">";
       echo "<B><CENTER>";
-      echo _("Viewing a plain text attachment");
+      echo _("Viewing a text attachment") . " - ";
+      echo "<a href=\"read_body.php?mailbox=$mailbox&passed_id=$id\">". _("View message") . "</a>";
       echo "</CENTER></B>";
       echo "</TD></TR><TR><TD BGCOLOR=\"$color[4]\">";
       $urlmailbox = urlencode($mailbox);
             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":
             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;