#!/usr/bin/perl -w
use CGI;
my $q = CGI->new;
my $f = $q->upload('upfile');
print "Content-Type: image/png\n\n";
open PDF, q(>), q(/tmp/t.pdf);
print PDF while (<$f>);
close PDF;
system qq(convert /tmp/t.pdf -rotate 270 /tmp/t.png);
print qx(cat /tmp/t.png);
没有评论:
发表评论