#!/usr/local/bin/perl -w use strict; use lib "/home/dtech/public_html/cgi-bin/utility"; use DTec; &run; sub run { my ($finalOutput,$query,$dbh); $query = &getCGI; $dbh = &dbConnect || print "Could not connect to the database"; print $query->header; # Get the index page. $finalOutput = BuildMainIndex($dbh, $query); # Clean up. $dbh->disconnect; print $finalOutput; }