RE: Need a perl module

2005-06-07 Thread olaloux
Use the MIME modules: MIME::Base64; MIME::QuotedPrint; Some other exist, but these can decode a large range of mail. You need to parse the mail with your code, but these modules allow you to decode the text + attachments. Do you need a sample of code? Olivier I need a perl module that

RE: RE: Need a perl module

2005-06-07 Thread olaloux
A part of code: # This part of code can receive a mail on STDIN and parse it # This mail is composed of 3 parts: # o) a body (text) # o) an attached file (a picture in my case) # o) specifications of the attached file (text, a short description in my case) # use strict; use MIME::Base64; use MIME:

RE: RE: RE: Need a perl module

2005-06-07 Thread olaloux
An error slipt into the code, here is the corrected part ;-) # Decoding of part 1 (the body) CORRECT ONE if ($content_type_att_1=~m/base64/i) { $body=MIME::Base64::decode(trim($body)); } elsif ($content_type_att_1=~m/quoted-printable/i) { $body=decode_qp($body); } # HAPPY PERL CODING A par