X-Git-Url: http://git.freeside.biz/gitweb/?p=freeside.git;a=blobdiff_plain;f=rt%2Fshare%2Fhtml%2FDownload%2FCustomFieldValue%2Fdhandler;h=069f2c00fdbfce4dde87bf98eec90b5faccd2c5e;hp=a9190491f4a55ec2bf7a1fedb94df2d73ea66168;hb=de9d037528895f7151a9aead6724ce2df95f9586;hpb=7588a4ac90a9b07c08a3107cd1107d773be1c991 diff --git a/rt/share/html/Download/CustomFieldValue/dhandler b/rt/share/html/Download/CustomFieldValue/dhandler index a9190491f..069f2c00f 100644 --- a/rt/share/html/Download/CustomFieldValue/dhandler +++ b/rt/share/html/Download/CustomFieldValue/dhandler @@ -2,7 +2,7 @@ %# %# COPYRIGHT: %# -%# This software is Copyright (c) 1996-2013 Best Practical Solutions, LLC +%# This software is Copyright (c) 1996-2017 Best Practical Solutions, LLC %# %# %# (Except where explicitly superseded by other copyright notices) @@ -61,13 +61,13 @@ unless ($OCFV->id) { Abort("Bad OCFV id. Couldn't find OCFV '$id'\n"); } -my $content_type = $OCFV->ContentType || 'text/plain'; +my $content_type = $OCFV->ContentType || 'text/plain; charset=utf-8'; if (RT->Config->Get('AlwaysDownloadAttachments')) { $r->headers_out->{'Content-Disposition'} = "attachment"; } elsif (!RT->Config->Get('TrustHTMLAttachments')) { - $content_type = 'text/plain' if ($content_type =~ /^text\/html/i); + $content_type = 'text/plain; charset=utf-8' if ($content_type =~ /^text\/html/i); } $r->content_type( $content_type );