Hi everyone
Just tried the MIME::Lite module for the 1st time,
the download/install went "OK", but it got some weird error I can't figure out.
my (entire) code was:
use MIME::Lite;
my $msg = MIME::Lite->new(
From =>'some@one.com',
To =>'realmail@gmail.com',
#Cc =>'some@other.com, some@more.com',
Subject =>'testing 1 2 3',
Data =>"body thing, back slash n test\n, br ing test<br> thats i
+t"
);
$msg->send(); #this one is line 10
straight from the examples (cpan), of the module's page.
But when it Run, it just dies saying:
SMTP Failed to connect to mail server: Bad file descriptor
at C:\Documents and Settings\Administrator\Desktop\perl experiments\m
+ail sender.pl line 10
Press any key to continue . . .
so I added "use diagnostics;"
and this time it died saying:
Uncaught exception from user code:
SMTP Failed to connect to mail server: Bad file descriptor
at C:\Documents and Settings\Administrator\Desktop\perl experiments\m
+ail sender
.pl line 12
at C:/strawberry/perl/site/lib/MIME/Lite.pm line 2865
MIME::Lite::send_by_smtp('MIME::Lite=HASH(0xc9b62c)') called a
+t C:/straw
berry/perl/site/lib/MIME/Lite.pm line 2574
MIME::Lite::send('MIME::Lite=HASH(0xc9b62c)') called at C:\Doc
+uments and
Settings\Administrator\Desktop\perl experiments\mail sender.pl line 1
+2
Press any key to continue . . .
Any ideas ???
Thx
Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
Read Where should I post X? if you're not absolutely sure you're posting in the right place.
Please read these before you post! —
Posts may use any of the Perl Monks Approved HTML tags:
- a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
| |
For: |
|
Use: |
| & | | & |
| < | | < |
| > | | > |
| [ | | [ |
| ] | | ] |
Link using PerlMonks shortcuts! What shortcuts can I use for linking?
See Writeup Formatting Tips and other pages linked from there for more info.