my $file = $cgi->param('upload'); my $content_type = $cgi->uploadInfo($file)->{'Content-Type'};