Anonymous Monk has asked for the wisdom of the Perl Monks concerning the following question:
below is a script that suppose to send an email with a single attachment (doc file) the script send the mail but split the attachment to multiple parts (14) )i guess its because the Type=>), any idea on how to resolve this issue ?
use strict; use warnings; use FindBin; use Net::SMTP::TLS; use MIME::Lite; use lib ("$FindBin::Bin/CPAN"); my $msg = MIME::Lite->new( From => 'mail', To => 'mail', Subject => 'Perl Test', Type =>'multipart/signed', ); $msg->attach( Type => 'application/msword', Path => 'some path', Filename => 'FORM50.doc', Disposition => 'attachment', ); my $mailer = new Net::SMTP::TLS( 'smtp.gmail.com', Port => 587, User => 'user', Password=> 'password'); $mailer->mail('mail'); $mailer->to('mail'); $mailer->data; $mailer->datasend($msg->as_string); $mailer->dataend; $mailer->quit;
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: MIME::lite and Net::SMTP::TLS - split attachment
by ig (Vicar) on Jul 04, 2011 at 16:56 UTC | |
|
Re: MIME::lite and Net::SMTP::TLS - split attachment
by aturtle (Novice) on Oct 01, 2011 at 17:59 UTC | |
by Anonymous Monk on Mar 12, 2015 at 13:20 UTC | |
by Anonymous Monk on Oct 17, 2012 at 17:38 UTC | |
by Anonymous Monk on Dec 21, 2012 at 02:54 UTC | |
by Anonymous Monk on Mar 05, 2015 at 11:12 UTC | |
|
Re: MIME::lite and Net::SMTP::TLS - split attachment
by jethro (Monsignor) on Jul 05, 2011 at 08:47 UTC |