October 24th, 2011, 04:54 PM
Urgent regex help required
Hi, please could somebody give me some direction or an answer to my dillema, I have tried but I am comming up short each time.
We have a script that runs a regex preg_match_all against emails returned from an email account that have bounced from our bulkmail system, the script as it is runs fine however we end up getting mails back where the email address is prepended with an rfc822; on the email address, making the email address rfc822;mikey @ somedomain .co .za which is returned in the array of emails found in the raw mail body.
This obviously does not match the email address in the db and therefore never gets removed from the db, I need this following regex expresion to be changed/modified so that if an address is prepended with rfc822; it just returns the(E-Mail address mikey @ somedomain . co .za and if it is not prepended the email address will be returned only
October 24th, 2011, 05:27 PM
Since semicolons would be invalid anyways,
October 25th, 2011, 03:38 AM
you are a star, that worked a treat.