X-Git-Url: http://git.freeside.biz/gitweb/?a=blobdiff_plain;f=rt%2Fshare%2Fhtml%2FTicket%2FAttachment%2Fdhandler;h=8b41329bab4654d5305e83b2fda96bbe89bc9555;hb=e70abd21bab68b23488f7ef1ee2e693a3b365691;hp=d4d556b24531c29b93000288eff39d5ccf8babcb;hpb=b4b0c7e72d7eaee2fbfc7022022c9698323203dd;p=freeside.git diff --git a/rt/share/html/Ticket/Attachment/dhandler b/rt/share/html/Ticket/Attachment/dhandler index d4d556b24..8b41329ba 100755 --- a/rt/share/html/Ticket/Attachment/dhandler +++ b/rt/share/html/Ticket/Attachment/dhandler @@ -68,8 +68,11 @@ } my $content_type = $AttachmentObj->ContentType || 'text/plain'; - - unless (RT->Config->Get('TrustHTMLAttachments')) { + + if (RT->Config->Get('AlwaysDownloadAttachments')) { + $r->headers_out->{'Content-Disposition'} = "attachment; filename=" . $AttachmentObj->Filename; + } + elsif (!RT->Config->Get('TrustHTMLAttachments')) { $content_type = 'text/plain' if ($content_type =~ /^text\/html/i); }