Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP

Loading…

[#29417] sendMail automatically adds sender as replyTo #469

Closed
wants to merge 1 commit into from

3 participants

@dextercowley

Fixed in master. Thanks!

@dextercowley

Fixed in 2.5.x branch. Thanks!

@Sfinxjoomla

Hi phproberto. Hope you are still watching this topic. I have a similar problem and none of your solutions seems to work for me. I have problem with contact form on page (breezingforms - it is using joomla library) - if I check mailback as sender. There are 2 sceraios happening:
1.) If I use phpmailer or smtp in global config - only emails from secure domains arrive (gmail, yahoo & others never arrive). Option for reply to subbmiter is working. This "block" is supposed to be hosting anti spoofing policy, but I belive there could be a solution with the way joomla sends email.
2.) If I use SMTP with my gmail account. I receive all emails, but subbmitters email is only displayed as Name before admin email (submitter@example.com [adminmail@gmail.com]) . So when I reply it sends to admins email.

Do you guys have a solution for this? I am workingon this for over 14 days and I am loosing it....

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
This page is out of date. Refresh to see the latest.
Showing with 4 additions and 1 deletion.
  1. +4 −1 libraries/joomla/mail/mail.php
View
5 libraries/joomla/mail/mail.php
@@ -440,7 +440,6 @@ public function useSMTP($auth = null, $host = null, $user = null, $pass = null,
public function sendMail($from, $fromName, $recipient, $subject, $body, $mode = false, $cc = null, $bcc = null, $attachment = null,
$replyTo = null, $replyToName = null)
{
- $this->setSender(array($from, $fromName));
$this->setSubject($subject);
$this->setBody($body);
@@ -470,6 +469,10 @@ public function sendMail($from, $fromName, $recipient, $subject, $body, $mode =
$this->addReplyTo(array($replyTo, $replyToName));
}
+ // Add sender to replyTo only if no replyTo received
+ $autoReplyTo = (empty($this->ReplyTo)) ? true : false;
+ $this->setSender(array($from, $fromName, $autoReplyTo));
+
return $this->Send();
}
Something went wrong with that request. Please try again.