How do I parse E-Mail contents
How to parse the Email into sections like, header, body, attachment, and sender and receiver? I would like to use Perl or Perl开发者_开发问答 Moose?
see Mail::Message - general message object something like,
my $msg =Mail::Message->new($mail);
my $body = $msg->body;
my @to = $msg->to;
my @from = $msg->from;
or see Email::Simple - simple parsing of RFC2822 message format and headers.
Updated:
see also Email::MIME - Easy MIME message parsing.
精彩评论