A
artmerar
Hi,
Ok, our server runs Qmail. In the users home directory we can ut a file, .qmail, which acts like a .forward. So, we can take the incoming messages and forward them to a script:
| /home/johndoe/filter.pl
I want to take the emails and extract the From, To, Subject & Body. I was using Email::Filter and was getting everything, but the body contains all the tags & MIME information, etc.
I'm really looking to only get the body text, without all the tags, etc.
I tried Email::Filter, Email::MIME, MIME:arser, all with no luck. When I use Email::Filter I start like this: my $mail = Email::Filter->new();
That gives some type of Hash Array: Email::Filter=HASH(0x1f220730)
But all those Perl modules are expecting the input to come from 'somewhere'. But I'm not sure in this case where 'somewhere' is. It is not STDIN, it is not a file, it was forwarded via the .qmail file: | /home/johndoe/filter.pl
So very long story short, any example where I can extract the body text without all the MIME stuff?
Many thanks!
Ok, our server runs Qmail. In the users home directory we can ut a file, .qmail, which acts like a .forward. So, we can take the incoming messages and forward them to a script:
| /home/johndoe/filter.pl
I want to take the emails and extract the From, To, Subject & Body. I was using Email::Filter and was getting everything, but the body contains all the tags & MIME information, etc.
I'm really looking to only get the body text, without all the tags, etc.
I tried Email::Filter, Email::MIME, MIME:arser, all with no luck. When I use Email::Filter I start like this: my $mail = Email::Filter->new();
That gives some type of Hash Array: Email::Filter=HASH(0x1f220730)
But all those Perl modules are expecting the input to come from 'somewhere'. But I'm not sure in this case where 'somewhere' is. It is not STDIN, it is not a file, it was forwarded via the .qmail file: | /home/johndoe/filter.pl
So very long story short, any example where I can extract the body text without all the MIME stuff?
Many thanks!