RFC822 & Text of Mail Message

jam jam at p98.f112.n480.z2.fidonet.org
Fri Jul 2 03:29:33 EDT 1999


From: jam <jam at newimage.com>

On Fri, Jul 02, 1999 at 03:07:03PM +0000, gcollins99 at my-deja.com wrote:
> 
> Greetings!
> 
>   Here is what I want to do but cannot find out how. I am using RFC822
> to parse out the headers and store them somewhere which works just fine.
> But I am also in need of getting the text of the incoming message. So
> what module would I use to also capture the message text. I see no way
> of doing this via rfc822 module since it's not designed to do such
> things. WOuld I use mimetools? And if so, how?
> 
> Thanks!
> 
> -Glen Collins
> 

hi.

take a look at 'mailbox.py' in the standard library distribution for an example
of how to do this.  it boils down to calling 'rewindbody' and the 'read'ing
the data like any normal file.

good luck ! ;)

regards,
J
-- 
|| visit gfd <http://quark.newimage.com/> 
|| psa member #293 <http://www.python.org/> 
|| New Image Systems & Services, Inc. <http://www.newimage.com/>





More information about the Python-list mailing list