%#
%# COPYRIGHT:
%#
-%# This software is Copyright (c) 1996-2012 Best Practical Solutions, LLC
+%# This software is Copyright (c) 1996-2013 Best Practical Solutions, LLC
%# <sales@bestpractical.com>
%#
%# (Except where explicitly superseded by other copyright notices)
use LWP::MediaTypes;
use RT::Interface::REST;
use File::Temp qw(tempfile);
+my @tmp_files;
my $ticket = RT::Ticket->new($session{CurrentUser});
my $object = $r->path_info;
}
my $cgi = $m->cgi_object;
-my $ent = MIME::Entity->build(Type => "multipart/mixed");
+my $ent = MIME::Entity->build(
+ Type => "multipart/mixed",
+ 'X-RT-Interface' => 'REST',
+);
$ent->attach(Data => $k->{Text}) if $k->{Text};
my $i = 1;
if ($fh) {
my $buf;
my ($w, $tmp) = tempfile();
+ push @tmp_files, $tmp;
my $info = $cgi->uploadInfo();
while (sysread($fh, $buf, 8192)) {
}
OUTPUT:
+
+unlink @tmp_files;
</%INIT>
RT/<% $RT::VERSION %> <% $status %>