Hello everyone, wanted to get pointed in the right direction or see if this is even possible. I have some basic emails one of my inboxes receives that are all in a standard format. If there any way to code a script that can read any new emails an account has, parse the requested data from that email (name, phone number, date), and then assign that data to a variable? I assume if it can be done I can use cron commands to execute the command every so often... What I will end up doing is running an SQL query with those variables after the fact, but I can handle that pretty easily. So the biggest thing mentioned above- can I parse data from all incoming emails and assign that data to variables? Even a pointer in the right direction will help! Thanks!
Yes, you can do it, if POP is enabled for the mail account you are talking about. Here is the flow: 1. Read emails via POP3. 2. Loop through each mail and parse the data by the format of the email. 3. Store email content & data in a database table for reference. 4. Process the data the way you wish.
Sounds like a pretty straight forward process. I am going to start at the beginning and find out how to read emails through php. Thats all new to me