Hi,
I have a simple sendmail and it does not return an error but yet the mail does not send.
The page is:
http://grad.dazedthoughts.com/emailTEST.html
the cgi is:
#!/usr/local/bin/perl -wT
use CGI qw(:all);# imports the CGI.pm module
use HTML::Template; #imports the template module which allows for separation of Perl and HTML
#local variables all start with my
my ($email, $from, $subject);
#creates the variable from the form input with the name email
$email = param(‘email’);
generate html feedback
print “Content-type: text/html\n\n”;
print "Your email address ($email) has been successfully entered. ";
print “Thank you. You will receive a confirmation email shortly.”;
#########creates email
$subject = Confirmation Email
$from = "debbie@dazedthoughts.com";
open (MAIL, “|/usr/sbin/sendmail -t”) || &ErrorMessage;
print MAIL “To: $email \nFrom: $from\n”;
print MAIL “Subject:\n”;
print MAIL “Confirmation Email\n\n”;
print MAIL "Thank you for signing up. Your email address ($email) has been successfully ";
print MAIL “stored. Have a nice day.\n”;
close (MAIL);
sub ErrorMessage {
print “
The server has a problem. Aborting script. \n”;
exit;
}
thanks in advance for any help that you can give me.
Debbie