#!/usr/bin/perl -w use strict; use CGI qw(:standard); use CGI::Carp qw(fatalsToBrowser); my $Typeofprint = param('typeofprint'); open (DB, 'DB.db') or die $!; my $i; print CGI::header(); print << "_HEAD_"; Street Print CD Catalog

Click to enlarge

Application Type

_HEAD_ print ''; while (my $line = ) { chomp $line; $line =~ tr/\r\n//d;## get rid of end of lines from windoze my @record = split /\|/, $line, 3; my $name = $record[0]; $name =~ s/sr.jpg//; if (defined($record[2]) && $record[2] =~ /\b$Typeofprint\b/i or $Typeofprint eq 'All') { print << "_TABLE_"; _TABLE_ $i++; } if ($i % 3 == 0) { print ""; } } print "

$name
";