use CGI; my $q = CGI->new; print $q->header( -type => 'application/vnd.ms-excel', -Content-disposition => 'attachment; filename=BOBreports.xls', -pragma => 'no-cache', -expires => 'now', ); print $q->param('hiddenExportText'), "\n";