Pipe email to PHP - get mail adress from MySQL - send?
Posted on
16th Feb 2014 07:03 pm by
admin
Hi all,
this is the challenge:
Did you know?Explore Trending and Topic pages for more stories like this.
1) Our faculty at the college where I'm employed includes quite a bit of freelancers that don't check the college mailbox quite as often as the administration would like.
2) I have created forwarders in the form firstname.lastname@ourcollege.com, forwarded to their private mailboxes. That has worked fine up until now.
3) Lately we implemented Moodle as a course platform. As Moodle relies on a MySQL backend, this gave me the idea that something much more flexible would be possible.
I would need a php script that
1) grabs the email piped from cPanel,
2) extracts the email address 'just before', that is, the part in the header that indicates where it were piped from (is that possible? - I'm talking about the last part in a rather complex group mail forwarding sceme, just before the pipe = (ie staff@ourcollege.com->teachers@ourcollege.com->firstname.lastname@ourcollege.com),
3) queries the MySQL database by this field (official_email) and brings back another related field (private_email),
4) forwards the original email to that private e-mail address.
This would give us the opportunity to have our "forwarders -> real mail adresses' list constantly up-to-date, as all the freelancers could keep their records up to date all by themselves through the moodle user front-end interface.
This is, however, beyond me. I know the basics of piping from cPanel, and some rudimental PHP and MySQL, but that's it. Any help would be most appreciated.
No comments posted yet
Your Answer:
Login to answer
103
30
Other forums
need help with date function
i have following form for date
Code: <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01
Contents of variable not echoing
Hey guys, hopefully this is an easy one...
In this line, the variables are not echoing out. T
New Login Script
Hi all, i attempted to create a whole new login script witch isnt working for some reason i dont kno
Taylor Series Function
So I am working a a project for my intro C++ class, and I am having some trouble with a function for
Please Help my PHP Dating Function.
Hi everyone!
Well here is my code that displays this:
It works wonderful.
help removing unwanted graphic
How do I remove the small elongated rectangular shape between the "Latest post" and "
Echo-ing MySQL content and Keep Formatting?
I have data in my MySQL such as:
QuoteBlah blah
Blah blah
etc
but when i ech
http to https
Hi,
Is there any specific method/condition to move an http:// page to https:// ?
Need help with basic sql
Hi,
I am using oracle 10g, and having some small doubts related to sql , here goes the si
Concatenate two strings ???
I have string one $string1 and another $string2.
How to concatenate (add) both of them $str