From: "Gunnar Hjalmarsson" <nore...@gunnar.cc>
however until that new module will be ready... I need to use Email::Send, because it allows sending in many ways, using SMTP, Sendmail, Qmail, Google and a few others.

Why is it important to have a mail sending module hunt for various mailer programs?

It is important because some users might want to use Sendmail, some Qmail, some an SMTP server, some Gmail or other methods. The best email client would need to be able to use any method.

My personal favorite is Jenda's Mail::Sender. This is an example of how that module might be used to send the OP's message:

#!/usr/bin/perl

I have also used this module, but I had some issues with it when I needed to use special UTF-8 chars in the program.

First, Mail::Sender is too low level so I've used Mail::Sender::Easy which was much easier to use. Mail::Sender::Easy is based on Mail::Sender.

Mail::Sender doesn't encode the headers to UTF-8 and we would need to do that MIME encoding explicitly which is something I wouldn't like. If you put some chars like astâîASTÂÎ in any header of the message like the To:, From: or the subject of the message, the message might not be sent because it might be blocked due to the fact that the headers are not encoded well.

This happends no matter if I use "use utf8;" in the program or not.

Then Mail::Sender doesn't support creating the messages or the attachments from templates and I guess it also doesn't encode the body of the message to UTF-8 and we would need to do it explicitly.

For simple things however, Mail::Sender::Easy is good.

Octavian


--
To unsubscribe, e-mail: beginners-unsubscr...@perl.org
For additional commands, e-mail: beginners-h...@perl.org
http://learn.perl.org/


Reply via email to