#!/usr/bin/perl ########################################################################### &parse_form; $surname=$FORM{'surname'}; # # Display the page # print "Content-type: text/html\n\n"; print "Death Certificates, Mercer Co. Ky\n\n"; print "\n\n"; open (MENU, "/u1/home0001/usa/ky/kymercer/public_html/menu.txt"); while () {print;} close (MENU); print "

\n\n"; print "

Mercer County Ky.
Death Certificates"; print "

\n\n"; print "
\n"; print "[ Search 1911-2000 (index only) ] "; print "[ see below for transcribed copies ] "; print "[ Order actual copies 1911-1954 ] "; print "


\n\n"; print "
\n"; print "I'm in the process of transcribing the Death Certificates for Mercer County, "; print "for the years 1911-1925. These certificates are searchable \n"; print "(what else? \<\;g\>\;) by surname. You will be given all certifcates \n"; print "available for that surname, whether it be the deceased, a parent of the \n"; print "deceased, the spouse of the deceased, or the informant for the death \n"; print "certificate.

\n"; print "Please enter the surname below, then hit the 'submit' button. HAPPY HUNTING!!!

\n"; print "Surname (Last, First M. - or just last, etc.): \ \; \ \; \ \; \ \; \ \;"; print " \n"; print "

\n"; # # Select which records to print # if ($surname) { print "


If no certs appear below, there are none that match the name that "; print "you selected. Either try another name, or check back again later.

\n\n"; print "

Name entered: $surname


\n\n"; open (DB, "/u1/home0001/usa/ky/kymercer/public_html/datfiles/dc.db"); while () { chop; ($cert,$name,$maiden,$born,$birthplace,$died,$status,$father,$fborn,$mother,$mborn,$informant,$inf_of,$buried,$cause,$spouse)=split(/:/,$_); if (($name=~/^$surname/i) || ($maiden=~/^$surname/i) || ($father=~/^$surname/i) || ($mother=~/^$surname/i) || ($informant=~/^$surname/i) || ($spouse=~/^$surname/i)) { push(@list,"$name:$cert:$maiden:$born:$birthplace:$died:$status:$father:$fborn:$mother:$mborn:$informant:$inf_of:$buried:$cause:$spouse"); } } foreach $item (sort @list) { ($name,$cert,$maiden,$born,$birthplace,$died,$status,$father,$fborn,$mother,$mborn,$informant,$inf_of,$buried,$cause,$spouse)=split(/:/,$item); $name="$name<\/b><\/font>" if ($name=~/^$surname/i); $maiden="$maiden<\/b><\/font>" if ($maiden=~/^$surname/i); $father="$father<\/b><\/font>" if ($father=~/^$surname/i); $mother="$mother<\/b><\/font>" if ($mother=~/^$surname/i); $informant="$informant<\/b><\/font>" if ($informant=~/^$surname/i); print "

\n"; print "\n"; print "\n"; print "\n"; print "\n"; print "\n"; print "\n"; print "\n"; print "\n"; print "
$nameCert #: $cert
Born: $bornPlace: $birthplace
Died: $died Mercer Co.Cause: $cause
Marital Status: $statusSpouse: $spouse
Father: $fatherBorn: $fborn
Mother: $motherBorn: $mborn
Informant: $informantof $inf_of
Buried: $buried


\n\n"; } } print "

Pam Carey Ison / Junction City, KY / kymercer\@roadrunner.com\n"; print "
\n"; ########################################################################### sub parse_form { read(STDIN, $buffer, $ENV{'CONTENT_LENGTH'}); @pairs = split(/&/, $buffer); foreach $pair (@pairs) { ($name,$value)=split(/=/,$pair); $value =~ tr/+/ /; $value =~ s/%([a-fA-F0-9][a-fA-F0-9])/pack("C",hex($1))/eg; $FORM{$name} = $value; } }