Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Managing bounced emails from PHP 1

Status
Not open for further replies.

Sleidia

Technical User
Joined
May 4, 2001
Messages
1,284
Location
FR
Hi guys :)

According to you, what's the best way to automatically delete bounced emails from a mysql/php driven mailing list without having to pick every bad email address manually?

My current knowledge would lead me to do it this way :
1. set a cron job that runs imap functions that read all the messages in the mailbox
2. while reading, flag messages for deletion if they contain some specific text string (ie: Mail Delivery Subsystem)
3. Remove the faulty address from the database.
4. Finally, delete the faulty message from the mailbox while exiting imap.

With this method, the drawbacks are :
a) can't make the difference between "soft bouncing" (mailbox full) and "hard bouncing"
b) won't be able to filter messages that return uncommon errors messages.

So, are there better solutions?
How could I avoid the drawbacks listed above?

By any chance, do you know about free mailing lists php applications that manage bouncing?

Thanks !
 
The way you're describing is probably the only way to do it.

But you're going to have to develop some pretty complex message-body parsing to detect the difference between soft and hard bounces.



Want the best answers? Ask the best questions! TANSTAAFL!
 

Thanks Sleipnir :)

Well ... I really hoped that there was a better (and simpler) way ;)

You're right about the message-body parsing.
I think I will keep it simple in the beginning and then, add more text strings little by little by observing the content of the messages that don't get deleted.

I'm still open to new ideas anyway.

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top