Solved

I need a script which will forward e-mails using a mysql database

Posted on 2004-10-16
7
167 Views
Last Modified: 2011-09-20
I need a script (preferably PHP or Perl) which can check a POP3 box, get the e-mails and forward them depending on the TO to a address stored in a MySQL database which matches the TO.

If that doesnt exist then a way to do it using a mail server (dont care which one) will do.
0
Comment
Question by:nickstallman
  • 3
  • 2
7 Comments
 
LVL 2

Expert Comment

by:udayms
ID: 12331453
Hi,
Can you explain the purpose of the whole excersise. Maybe there are easier ways to achieve your end result than all these.

-Uday
0
 

Author Comment

by:nickstallman
ID: 12331468
Ok. Basically I have a list of usernames and e-mail addresses in a MySQL database and I have a wildcard forward to a pop3 address.

I need a script which can forward username@mydomain the e-mail address associated with the username.
0
 
LVL 2

Expert Comment

by:udayms
ID: 12331497
Ok.. Nick... I am assuming that you are using a thirdparty webspace provider's service. In that case you wouldnt be able to install any Mail management software on the server. The other option is to have a program that does this task. Try out this link... You might find some useful info there in.
http://www.hotscripts.com/Detailed/35656.html

Or you can take 2 php scripts - 1 that picks  out email ids and contents from the inbox and another that sends  mails from MYSQL DB and then combine them. This miight be a bit time consuming. Besides, in these choices the biggest problem we will have is that someone will have to manually trigger the page/program for it to work. So basically somebody will have to run the process at the end of the day so that all the mails are routed to their respective mail boxes.
0
Courses: Start Training Online With Pros, Today

Brush up on the basics or master the advanced techniques required to earn essential industry certifications, with Courses. Enroll in a course and start learning today. Training topics range from Android App Dev to the Xen Virtualization Platform.

 

Author Comment

by:nickstallman
ID: 12331555
Thanks for that one. It'll be useful if I need to make the script myself.

I have a Windows dedi in my house so I can have a mail server running.

Running the program every few miniutes isnt a problem. A Cron job or a scheduled task will do it easily.
0
 

Author Comment

by:nickstallman
ID: 12331621
I have found my solution:
http://www.gentoo.org/doc/en/virt-mail-howto.xml

Its not a script like I wanted but it'll do the job.
0
 

Accepted Solution

by:
modulo earned 0 total points
ID: 12577703
PAQed with points refunded (500)

modulo
Community Support Moderator
0

Featured Post

Courses: Start Training Online With Pros, Today

Brush up on the basics or master the advanced techniques required to earn essential industry certifications, with Courses. Enroll in a course and start learning today. Training topics range from Android App Dev to the Xen Virtualization Platform.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
XML problem with Internet Explorer 7 45
Tool to email me when a website changes 29 128
CSS HELP 6 88
CSS display:none AND display:block on same element 3 90
What is Node.js? Node.js is a server side scripting language much like PHP or ASP but is used to implement the complete package of HTTP webserver and application framework. The difference is that Node.js’s execution engine is asynchronous and event…
SASS allows you to treat your CSS code in a more OOP way. Let's have a look on how you can structure your code in order for it to be easily maintained and reused.
The viewer will learn how to count occurrences of each item in an array.
The viewer will the learn the benefit of plain text editors and code an HTML5 based template for use in further tutorials.

786 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question