> Hi Dan,

Hey,

> 
> Thanks for replying to my email.  I looked at the 

No prob. Although please don't request read receipts for mailing 
lists and please post to the list and not just me so all can share.

> documentation on Mail::Internet and did not find it very 
> helpful.  Could you please send me your perl code that uses 
> this module. 

This isn't homework is it?
Well I'm a sucker eitherway :)

#!/usr/bin/perl -w

use strict;
use Mail::Internet;

my $mail = Mail::Internet->new(\*STDIN);
my $headers = $mail->head->header_hashref;

That will get the headers into a convenient hash
Also you can us ethe $mail object to do any other methods listed on 
the cpan page.

This way you can have the mail prog pipe the mail into this and it will 
come in on STDIN and away you go!

HTH

DMuey


> 
> Thanks,
> 
> Trevor
> 
> -----Original Message-----
> From: Dan Muey [mailto:[EMAIL PROTECTED]
> Sent: Wednesday, June 18, 2003 1:46 PM
> To: Morrison, Trevor (Trevor); [EMAIL PROTECTED]
> Subject: RE: Parsing Emails
> 
> 
> > > Hi,
> 
> Howdy,
> 
> > > 
> > > I need to be able to parse incoming emails so that I write
> > the data to
> > > a MySQL database.  Is there a CPAN module that could assist
> > me in this.  Something like a template module but only in 
> the reverse.
> 
> I use Mail::Internet to parse emails form STDIN and 
> the DBI to put my goodies into mysql.
> 
> HTH
> 
> DMuey
> 
> > > 
> > > Thanks in advance
> > > 
> > > Trevor
> > 
> 

--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to