Hi Guys,
I'm trying to parse an email coming from <STDIN>. I need to parse the email and insert into a database.
The major problem I'm finding is trying to deal with all of the various mime-types. If it contains an attachment or is multipart/alternative, multipart/mixed or whatever then it's very complex to decode. In the end, I'd just to insert a text-only part of the email into the database. I've tried google (groups, various pages), cpan (Mime::Parse, Internet::Mail, etc), and various scripts from Hotscripts - none of which worked.
Does anyone know of some code that will allow me to extract the text only part of an email? If anyone can help it would be really appreciated.
I'm trying to parse an email coming from <STDIN>. I need to parse the email and insert into a database.
The major problem I'm finding is trying to deal with all of the various mime-types. If it contains an attachment or is multipart/alternative, multipart/mixed or whatever then it's very complex to decode. In the end, I'd just to insert a text-only part of the email into the database. I've tried google (groups, various pages), cpan (Mime::Parse, Internet::Mail, etc), and various scripts from Hotscripts - none of which worked.
Does anyone know of some code that will allow me to extract the text only part of an email? If anyone can help it would be really appreciated.