my $sender = Mail::Transport::SMTP->new(...); $sender->send($message); $message->send(via => 'smtp');
See SYNOPSIS in Mail::Transport::Send
This module implements transport of Mail::Message
objects by negotiating
to the destination host directly by using the SMTP protocol, without help of
sendmail
, mail
, or other programs on the local host.
See DESCRIPTION in Mail::Transport::Send