#!/usr/local/bin/perl
#Written by Lee Tze Meng using PERL !! The Camel


################################################## 
# set this to your cgi-bin directory
push(@INC,"/.mosaic/cgi-bin");
require '../cgi-lib.pl';
##################################################

&ReadParse;
print &PrintHeader;

print "<body bgcolor=yellow> <font size=+4 align=center color=blue>";

################# Print the header ############### 
print "<h3>Thank you $in{Name}! Your entry has been sent to the guestbook 
successfully!<p>\n";
print "<h3>Your entry has been updated<p>";
print "Have a nice day ! </h3>\n";
print '<a href="gus.shtml">Back to Form</a>';
print '<BR>';
print '<a href="temp.html">View Guest Book</a>';

################ send the data to temp.html #############################
open (OUT, ">>temp.html") || die("Unable to open the file");

print OUT "Name: $in{'Name'}\n";
print OUT "<BR>";
print OUT "E-mail: $in{'email'}\n";
print OUT "<BR>"; 
print OUT "Org: $in{'Org'}\n";
print OUT "<BR>";
print OUT "Hobbies: $in{'hob'}\n";
print OUT "<BR>";
print OUT "URL: $in{'url'}\n";
print OUT "<BR>";

print OUT "<BR>";
print OUT "<HR>";
close (OUT);

