Hello, i'm trying to get a perl script to send mail through Mail::Sendmail and it's not working.
I put the SMTP server name my ISP gave me in Sendmail.pm. (When i check for my mail through this server, i need to specify my username and password. Would i have to do this for Mail::Sendmail? if so, how?) I succesfully connect to my ISP's SMTP server using the Dos prompt: telnet servername 25 (actually, after i type that dos command and Telnet opens the connection, i have no idea what to do so i'm only guessing it connects fine...) Maybe there's a really simple solution to this...any help would be greatly appreciated. I'm very new to all this and i have been looking for a solution for days wilth no success. Thank you very much for your time. Beans Apache error log: [Wed Aug 21 16:38:05 2002] [error] Premature end of script headers: c:/apache/cgi-bin/testmail.pl testmail.pl script: !c:/perl/bin/perl -w #testmail.pl - Send mail using Mail::Sendmail module use strict; #use CGI::Carp qw(fatalsToBrowser); use Mail::Sendmail; my $recipient = "myemail\@hotmail.com" ; my $sender = "myemail\@hotmail.com"; #set up hash containing mail message information my %mail =( >From => $sender, To => $recipient, Subject => "I'm sending you mail", Message => "This is the message body.\n" ); sendmail (%mail) or die "sendmail failure sending to $mail{to}: $!\n"; exit (0); -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]