This looks to be a very useful piece of code but I have tried it on a test message and it fails to pring the message body.
Here is the test email that I tried it on (email address, servers and IPs cleaned but otherwise the same):
From Ed.Davison@mccombs.utexas.edu Mon Jul 31 15:05:58 2006
Received: from 1.2.3.4 ([1.2.3.4]) by exchange.domain
([1.2.3.5]) via Exchange Front-End Server mail.domain
([1.2.3.6]) with Microsoft Exchange Server HTTP-DAV ; Mon, 31
+Jul 2006
15:05:58 +0000
Received: from laptop by mail.domain; 31 Jul 2006
10:05:57 -0500
Subject: test for email parser
From: username@domain
Reply-To: username@domain
To: username
Content-Type: text/plain
Organization: Organization
Date: Mon, 31 Jul 2006 10:05:57 -0500
Message-Id: <1154358357.11169.0.camel@localhost>
Mime-Version: 1.0
X-Mailer: Evolution 2.6.2
X-Evolution-Source: exchange://user@mail.domain/
Content-Transfer-Encoding: 8bit
test entry
Any ideas why the message body is not being picked up on this one?
-
Are you posting in the right place? Check out Where do I post X? to know for sure.
-
Posts may use any of the Perl Monks Approved HTML tags. Currently these include the following:
<code> <a> <b> <big>
<blockquote> <br /> <dd>
<dl> <dt> <em> <font>
<h1> <h2> <h3> <h4>
<h5> <h6> <hr /> <i>
<li> <nbsp> <ol> <p>
<small> <strike> <strong>
<sub> <sup> <table>
<td> <th> <tr> <tt>
<u> <ul>
-
Snippets of code should be wrapped in
<code> tags not
<pre> tags. In fact, <pre>
tags should generally be avoided. If they must
be used, extreme care should be
taken to ensure that their contents do not
have long lines (<70 chars), in order to prevent
horizontal scrolling (and possible janitor
intervention).
-
Want more info? How to link
or How to display code and escape characters
are good places to start.
|