Email::MIME::Attachment::Stripper - Strip the attachments from a mail
my $stripper = Email::MIME::Attachment::Stripper->new($mail); my Email::MIME $msg = $stripper->message; my @attachments = $stripper->attachments;
Given a Email::MIME object, detach all attachments from the message. These are then available separately.
my $stripper = Email::MIME::Attachment::Stripper->new($mail, %args);
This should be instantiated with a Email::MIME object. Current arguments supported:
Try harder to get a filename, making one up if necessary.
my Email::MIME $msg = $stripper->message;
This returns the message with all the attachments detached. This will alter both the body and the header of the message.
my @attachments = $stripper->attachments;
This returns a list of all the attachments we found in the message, as a hash of { filename, content_type, payload }.
Casey West <casey@geeknest.com>
http://pep.kwiki.org
This module is incredibly closely derived from Tony Bowden's Mail::Message::Attachment::Stripper; this derivation was done by Simon Cozens (simon@cpan.org), and you receive this under the same terms as Tony's original module.
simon@cpan.org
To install Email::MIME::Attachment::Stripper, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Email::MIME::Attachment::Stripper
CPAN shell
perl -MCPAN -e shell install Email::MIME::Attachment::Stripper
For more information on module installation, please visit the detailed CPAN module installation guide.