Multipart.pm
$smtp = Net::SMTP::MultiPart->new("mailrelay.someco.com"); $smtp->Header(To => "someone\@someco.com", Subj => "Multipart Mail Demo", From => "me\@someco.com"); $smtp->Text("This is the first text part of the message"); $smtp->FileAttach("c:/tmp/myfile.xls"); $smtp->End();
This module uses the Net::SMTP and Mime::Base64 modules to compose and send multipart mail messages. It uses the Net::SMTP methods, but simplifies formatting of multipart messages using its internal methods Header, Text, FileAttach and End.
Carp
MIME::Base64
Net::SMTP
strict
vars
Dave Roberts
You can send bug reports and suggestions for improvements on this module to me at DaveRoberts@iname.com. However, I can't promise to offer any other support for this script.
This script is Copyright © 2002 Dave Roberts. All rights reserved.
This script is free software; you can redistribute it and/or modify it under the same terms as Perl itself. This script is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. The copyright holder of this script can not be held liable for any general, special, incidental or consequential damages arising out of the use of the script.
$Log: Multipart.pm $ Revision 1.4 2002/04/05 11:36:33 Dave.Roberts change to version number generation code
Revision 1.3 2002/03/27 09:16:29 Dave.Roberts initial pod added
Revision 1.2 2002/03/26 12:03:23 Dave.Roberts added basic pod structure