in reply to Printing Like Terminal Does

I don't think you really want to do what you think you want to do, but here it is:

#!/usr/bin/perl -w use strict; use CGI qw(:all); my $url = url(); my $high = defined(param('high')) ? param('high') + 1 : 0; my $timeout = 1; my %refresh_directive = $high >= 9 ? () : (-head => meta({ -http_equiv => 'refresh', -content => "$timeout;url=$url?high=$hi +gh"})); print header(), start_html(%refresh_directive); for (0 .. $high) { print "$_<br>\n"; } print end_html();