# perlregular.pl 
#     07.08.26
use strict;
use HTML::Template;

my(%t,@fld);

my $template = HTML::Template->new(filename => 'perlregular0.htm');
my @loop = ();

open(IN,"perlregular.txt") or die "Can't open the file perlregular.txt\n";
while(<IN>){
    chomp;  
    @fld = split(/==>/);
    my %row = (
            N1 => $fld[1],
            C1 => $fld[2]
    );
    push(@loop, \%row);
}
close(IN);

$template->param(std_loop => \@loop);
open(OUT,">perlregular1.htm");
print OUT $template->output;
close(OUT);

exit;