2

Am using phpmailer to automate mails in a webapp I am writing. Even after adding replyto it is adding both the from and replyto ids into the "Reply To" field and when the reply button is used to reply to the mail in the email client the from address is automatically added in the "To" address of the reply. I have tried using the solution as detailed in phpmailer: Reply using only "Reply To" address . But that is also not working. Any help will be greatly appreciated.

$mail->Password   = USER_PASSWORD;
        $mail->AddReplyTo("xxx@yyy.org","abc");
        $mail->SetFrom("$from","$fromname");
        $mail->Subject    = $subject;
Community
  • 1
  • 1
  • Please provide your current non-functioning code. – Charles Dec 27 '13 at 08:05
  • There is no need for double quotes around the php variables $from and $fromname. (by the way i gues this won't solve the problem) – nowhere Dec 27 '13 at 08:10
  • Okay, now show us the headers from the mail that this generates. – Charles Dec 27 '13 at 08:11
  • Did you try to use the last version of phpmailer? I checked the class' code and noticed that the problem issued from the link you posted has already been solved. – nowhere Dec 27 '13 at 08:18
  • Set `$mail->SMTPDebug = true` to have debug logging output which you can use to see if there are any errors. could be your smtp server stripping them out. – Anthony Dec 27 '13 at 08:18
  • Have checked up the debugging log output and there are no errors present – Vinayak Mahadevan Dec 27 '13 at 09:13
  • The problem is solved. Tried changing the From and To Addresses and made them different. Then it started working. Thank you for all the help – Vinayak Mahadevan Dec 27 '13 at 09:57

1 Answers1

1

Please check your "AddReplyTo" and "SetFrom" email id was different or not??

Apurv Chaudhary
  • 1,672
  • 3
  • 30
  • 55