In addition to grinder I would like to advice you to have a further look at MIME::Entity.
Using its methods mime_type resp. effective_type on each MIME part you may find the "text/plain" part and process it.
You may use these methods on MIME::Parser objects.
############################################################ sub split_entity { ############################################################ local $entity = shift; # needs a MIME::Entity object my $num_parts = $entity->parts; # how many mime parts? if ($num_parts) { # we have a multipart mime message foreach (1..$num_parts) { split_entity( $entity->parts($_ - 1) ); } } else { # we have a single mime message/part # text if ($entity->effective_type =~ /^text\/(?!(html|enriched))/) { # do something } else { # do something different } } }
alex pleiner <alex@zeitform.de>
zeitform Internet Dienste
In reply to Re: email and MIME?
by projekt21
in thread email and MIME?
by cez
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |