Hi again!
I really need to thank you for your time.
Looks like there is another typo somwhere in there 'cause added what you told me to & still getting same error message, although when testing in MacPerl result is syntax ok.
Just to make sure, I am pasting the new script here exactly as it is now.
#!/usr/local/bin/perl
use strict;
use CGI;
my $query = new CGI;
# retrieve the information submitted on the form
# ' No reason to pre-declare your vars, just put
# the 'my' in when you create them.
my $name = $query->param('name');
my $contact = $query->param('contact');
my $leavingfrom = $query->param('leavingfrom');
my $destination = $query->param('destination');
my $timeofday = $query->param('timeofday');
my $month = $query->param('month');
my $day = $query->param('day');
my @year = $query->param('year');
my $numberofpeople = $query->param('numberofpeople');
my $emailaddress = $query->param('emailaddress');
my $comments = $query->param('comments');
my $email = $query->param('email');
# construct some test that indicates a reasonable form
# submission... something like make sure you got
# a name and reasonably well-formed email address
# if you did then send the email and redirect to the
# thankyou page. If you did not get a name and email,
# Print a complaint with some instructions.
if (($name =~ /\w/) && ($email =~ /.*?@.*?\..*/))
{
&send_the_email; # send email
&redirect('thanks'); # call redirect sub for thanks
}
else {
&redirect('ooops'); # Gripe about poorly filled form.
}
exit;
# ------------
# SUBS
#-----------------------------------------------
sub redirect
{
my $mode = shift;
if ($mode eq 'thanks') # name and email where OK
{
print $query->redirect ('
}
elsif ($mode eq 'ooops') # name or email weren't OK
{
print $query->header,
$query->start_html,
qq(<p>Incomplete submission. Please go back and
complete all data fields.</p>),
$query->end_html;
}
}
#-----------------------------------------------
sub send_the_email
{
open (MAIL, "|/usr/sbin/sendmail -t"

|| Eror ('open', 'mail program');
print MAIL "To: panamreserve\@hotmail.com\nFrom: $name\nSubject: Online Reservation for $month, $day, @year\n
<html><head><title>RESERVATION</title></head><body>
<h2>Reservation Information</h2>\n<b>Name: </b>$name\n
<p><b>Contact Telephone Number: </b>$contact\n
<p><b>Email Address: </b>$emailaddress\n
<p><b>Number of people in group: </b>$numberofpeople
<p><b>Leaving from: </b>$leavingfrom
<p><b>Destination: </b>$destination
<p><b>Date of travel: </b>$month, $day, @year, in the $timeofday
<p><b>Additional Comments:\n<p></b>$comments
</body></html>";
close (MAIL);
}
PLEASE NOTE though, that I have not made any thanks or oops messages, if I do need to do that please clarify.
Wating to here from you again. SO LONG!