Bounce Email handling with PHP?

Here is my scenario:

I have 2 email accounts: and

I want to send email to all my users with but then “reply to” (until here, my PHP script can handle it).

When, the email can’t be sent, it’s sent to, the error message could be 553 (non existent email …) etc.

My question is: How do I direct all those bounce emails (couldn’t-sent emails) to through a handling script to check for the bounce error codes?

What programming language should I be using for the “handling script”?

What would the “handling script” look like? Can you give a sample?

in other words:

What are the procedures I should follow to handle the bounce email ?