]> wagnertech.de Git - kivitendo-erp.git/blobdiff - SL/Mailer.pm
Bug #899 behoben: Buttons fuer neue Belege funktionierten nicht in den Listenansichte...
[kivitendo-erp.git] / SL / Mailer.pm
index 2cd3b437439d436e14b707af6ae81ea85fc0ac72..3cf2053648c5902f6bb2eb082f83c608ce382408 100644 (file)
@@ -193,8 +193,15 @@ $self->{message}
         return "$attachment : $!";
       }
 
+      # only set charset for attachements of type text. every other type should not have this field
+      # refer to bug 883 for detailed information
+      my $attachment_charset;
+      if (lc $application eq 'text' && $self->{charset}) {
+        $attachment_charset = qq|; charset="$self->{charset}" |;
+      }
+
       print OUT qq|--${boundary}
-Content-Type: $application/$self->{format}; name="$filename"; charset="$self->{charset}"
+Content-Type: $application/$self->{format}; name="$filename"$attachment_charset
 Content-Transfer-Encoding: BASE64
 Content-Disposition: attachment; filename="$filename"\n\n|;