Search code examples
phpmailer

Can I reply my own mails with PHPMailer, that's possible?


I need a information about PHPMailer about replying my own mails. I need send a empty mail(subject, body), and when the first mail sent second mail need sending with replying first mail. That's possible ?

I tried but never can repyling my own mails.


Solution

  • Yes, but PHPMailer won't do this for you. You will need to do it by getting and setting appropriate headers, in particular the Message-ID header that identifies each message, and the In-Reply-To and References headers which are used to track whether something is a reply. Probably the best way to see these working is to simulate it using your regular email client - Outlook, Gmail, Apple Mail – all of which will set those headers correctly.