Hi everyone.
First thanks for everyones help with the problems I
was having with getting net:stmp to install. The
person who suggested I install bundle-libnet (or maybe
it was libnet-bundle) hit the nail on the head. This
installed the net:smtp module.
I have a script that looks like this:
#Send E-mail for Critical Alerts
#Here we define our parameters
$to = '[EMAIL PROTECTED]';
$from = "Openview";
$body = "Critical Alert";
#Here we use the module $ pass parameters
use Net::SMTP;
$smtp = Net::SMTP->new('10.11.1.134');
$smtp->mail($ENV{USER});
$smtp->to($to);
$smtp->data();
$smtp->datasend("From: $from\n");
$smtp->datasend("To: $to\n");
$smtp->datasend("\n");
$smtp->datasend("$body");
$smtp->dataend();
$smtp->quit;
I copied most of it from the documentation but the
documentation doesnt seem to specify how to create a
subject field. Does anyone know how to do this? The
link to the module page is right here.
http://search.cpan.org/author/GBARR/libnet-1.16/Net/SMTP.pm
Thx again,
Leon
__________________________________
Do you Yahoo!?
Yahoo! SiteBuilder - Free, easy-to-use web site design software
http://sitebuilder.yahoo.com
_______________________________________________
Perl-Win32-Users mailing list
[EMAIL PROTECTED]
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs