Fúlvio Figueirôa wrote:
I don't need to use the SMTP procotol,
Well, you *do* need an SMTP server that you are allowed to use.
I need only send an email.
This is an example that makes use of my favorite module Mail::Sender
(written by Jenda, btw):
use Mail::Sender;
ref (new Mail::Sender -> MailMsg( {
smtp => 'localhost',
from => 'm...@example.com',
to => 'y...@example.com',
subject => 'Test',
msg => 'This is just a test message...',
} )) or die "Cannot send mail. $Mail::Sender::Error\n";
Stating 'localhost' as the SMTP server works on the box where I am, as
is the case on many other platforms. Otherwise you need to state the
actual host name of the SMTP server.
--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl
--
To unsubscribe, e-mail: beginners-unsubscr...@perl.org
For additional commands, e-mail: beginners-h...@perl.org
http://learn.perl.org/