Hi.
I'm trying to retrieve an attachment from an email. I've tried using the MIME modules, but can't get this working right.
The following is the email's content...
This is a multi-part message in MIME format.
------=_NextPart_000_0007_01C210A9.5C28F260
Content-Type: multipart/alternative;
boundary="----=_NextPart_001_0008_01C210A9.5C28F260"
------=_NextPart_001_0008_01C210A9.5C28F260
Content-Type: text/plain;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable
Hi This is a test. Ralph.
------=_NextPart_001_0008_01C210A9.5C28F260
Content-Type: text/html;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable
http-equiv=3DContent-Type>
Hi This is a test.=20
Ralph.
------=_NextPart_001_0008_01C210A9.5C28F260--
------=_NextPart_000_0007_01C210A9.5C28F260
Content-Type: image/gif;
name="antipodi.gif"
Content-Transfer-Encoding: base64
Content-Disposition: attachment;
filename="antipodi.gif"
R0lGODlheAARAKIAAPbNzfvo6P////GqquRZWdwsLNkZGdYBASwAAAAAeAARAAAD/ii60LCQtSiC
gy7rp+zEGxBQEUAUhlEQA1mFHOnF3WEfo3wT0WDztZtQCBQAbhHD8GZoUQIEWwGFOhRoCt/yYCDk
INpDT+h8CmnaYmA7LB5tSbatrACsWJWCotscyw1fWUgQBUJ6OjeHggdFAgOPA1FzkDFvYhBKjJAE
mTgLAQUDoI+cpKJ9C1pNm4l+l3U2KTZYQTdlaS5hLpZxB3SWZVEnqwOrnFOKjlKudLoLkgTQiEI5
uCTOFLyYcxG2NQQAkQuHoAE+t8sRhYxggxU3DTeBQSo/i43tcCTaC5m/3spaPBpHcE0RLckWGcj3
CqGCdfjecQGmjN01dyUwCsgE/i5cMXkKOD1gEaBkgZKgHipy6IrhOG4VF0ZYw0WAJEDWKGDLqK+f
HF/PrFCJJuyE0JqLElZ8tXSRJ4lAIdCUCTFny30aOw1BFdLAg4EPCQqYkiqdy7L6JHFJ0SnhVKfS
LvbkyXTjD0gDaJ1zVEbRoS5olapySfMnjbch2+TSyCArTBfvvIgLm8dc1IpK4zqNSZQoR6mxPmmN
uBnrXLuXIQtDASlUJBVkA9NthsSfTpD0GFq8fbrxaduQO/RxzYlFqABe8xGL1IphmHlQyyAOak9u
Xd91gQc3cqdFyo0DQrnaAsiV5giSFE0XXp33dVi/H2+HIoWKEvHjhXSBHsYBG/QOF0hASwYuzFBg
gAL+B5kJKKiAhwwwQDZDAgA7
------=_NextPart_000_0007_01C210A9.5C28F260--
How can I retrieve the gif file from all this data?
The MIME module is really complex, and I can't seem to get this working in any way.
Please help.
Thanks,
Ralph.
In reply to
MIME Problem with Email
by
ralphch
Title:
Use:
<p> text here (a
p
aragraph) </p>
and:
<code> code here </code>
to format your post, it's "
PerlMonks-approved HTML
":
Posts are HTML formatted.
Put
<p> </p>
tags around your paragraphs. Put
<code> </code>
tags around your code and data!
Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
Read
Where should I post X?
if you're not absolutely sure you're posting in the right place.
Please read these before you post! —
How do I compose an effective node title?
How do I post a question effectively?
Markup in the Monastery
Posts may use any of the
Perl Monks Approved HTML tags
:
a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
For:
Use:
&
&
<
<
>
>
[
[
]
]
Link using PerlMonks shortcuts!
What shortcuts can I use for linking?
See
Writeup Formatting Tips
and other pages linked from there for more info.