Gossamer Forum
Home : General : Perl Programming :

Piping mail into a database...

Quote Reply
Piping mail into a database...
Hi folks,

I'm looking to write a small, basic webmail app, that takes email from an alias, rather than logging into POP3 or IMAP accounts.

It will be set up like this. In the virtmaps, the catch-all for the server will point to an alias. That alias will then route all mail into the perl application, in much the same way it is with Majordomo. Then that program will parse the email, decide who it's for from the To address, and send it on to a database, splitting up all the other details.

I shouldn't have any problems with parsing the mail and putting the details into a database, but I'm curious as to how to do the first step, i.e. passing the emails into the program.

if anyone has any suggestions or sample code to get me started, it would be much appreciated. Obviously the place to start is Majordomo, but that code is probably a little over my head, I'm just looking for something simple to get started with.

Cheers,
adam
Quote Reply
Re: Piping mail into a database... In reply to
I can't tell you how to do it, but I can point you to a resource that might have the answer.

Check out cgi-resources.com in their email area under PERL.

You will probably find something there.

Or, you could look around for Qmail and MySQL, since there are a few sites that use Qmail with MySQL probably for something similar to what you are doing Smile