#!/usr/local/bin/perl #script: nph-test_script_jmj.cgi use strict; use CGI qw(:standard -nph); $| = 1; ################### MAIN ########## CGI->nph(1); my $cgi = CGI->new(); print $cgi->header(-nph=>1); html_1(); print "my second is: " . mytime() . "
\n"; sleep 3; print "my second is: " . mytime() . "
\n"; html_2(); ############################################ sub html_1 { print "\n"; print "processing file
\n"; } sub html_2 { print "\n"; print "done processing file
\n"; } sub mytime { my ($sec) = localtime; return $sec; }