Welcome to the LimeSurvey Community Forum

Ask the community, share ideas, and connect with other LimeSurvey users!

reply-to is not set as expected. Where should I look?

More
2 years 6 months ago #219878 by bgray
I recently updated to LS version 5. I can't get invitation and reminder emails to have the "reply-to" email address that I want to use.

In the survey, I set an administrator name and administrator email address. I also set a bounce email address. When I send the invitations, the email comes from the generic email sender address I have configured in SendMail.ini (with the expected Administrator name text). There is no reply-to header in the emails.

I have get the same results if I use the SendMail or SMTP setting in Configuration > Global > Email settings. (Both settings target the same email server: smtp.gmail.com:587. The emails are delivered, but when recipients reply to the invitation, it goes to email sender account instead of the administrator.

I am using LS version 5.1.10+210913 running on Windows server with Apache and PHP 7.

Is this a problem with my LS configuration, or SendMail, or smtp.gmail.com? Where should I be looking?
The topic has been locked.
More
2 years 6 months ago #219929 by jelo
You need to stick to SMTP. If you upgrade from LS3 to LS5 it might be just a bug inside LimeSurvey. Gmail might filter or prevent setting a reply-to to prevent misuse.

I recommend to open a bugreport here.

The meaning of the word "stable" for users
www.limesurvey.org/forum/development/117...ord-stable-for-users
The topic has been locked.
  • DenisChenu
  • DenisChenu's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
2 years 6 months ago #219932 by DenisChenu
1. There are no Reply-to
2. «I have configured in SendMail.ini» Remove this … you surely badly update it.

Assistance on LimeSurvey forum and LimeSurvey core development are on my free time.
I'm not a LimeSurvey GmbH member, professional service on demand , plugin development .
I don't answer to private message.
The topic has been locked.
More
2 years 6 months ago - 2 years 6 months ago #219937 by bgray
Thanks for the suggestions. Based on your replies, I changed the configuration to use SMTP - still using smtp.gmail.com. 

I turned on email debugging. I can see that the "from" address that is sent to smtp.gmail.com is the survey administrator address (as expected), but when the invitation arrives in the recipient's inbox, the "from" address has been changed to the address of the authenticated user at smtp.gmail.com.  (This seems reasonable - it prevents address spoofing.)

I did some exploring in the LS code. In file LimeMailer.php, I added a line of code after line 529 to include a reply-to header:
Code:
       
if (empty($updateDisable['from'])) {
            $this->setFrom($event->get('from'));
            // added code:
            $this->addCustomHeader("Reply-To", $event->get('from'));
}


Adding the reply-to header here does what I need it to do. When the recipient clicks on the Reply button in email, the message is addressed to the survey administrator's email address instead of the account used to authenticate the smtp connection.

I will add it as a feature request if there isn't one already.
 
Last edit: 2 years 6 months ago by bgray. Reason: formatting fix
The topic has been locked.
  • DenisChenu
  • DenisChenu's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
2 years 6 months ago #219938 by DenisChenu

Assistance on LimeSurvey forum and LimeSurvey core development are on my free time.
I'm not a LimeSurvey GmbH member, professional service on demand , plugin development .
I don't answer to private message.
The topic has been locked.
More
2 years 6 months ago #219950 by bgray
That plug-in does what I need.

Thanks! 

bkg
 
The topic has been locked.
  • DenisChenu
  • DenisChenu's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
2 years 6 months ago #219968 by DenisChenu
Yes, sorry : i din't read the version …

> I recently updated to LS version 5.

In 5.X : the solution is really easy.

Assistance on LimeSurvey forum and LimeSurvey core development are on my free time.
I'm not a LimeSurvey GmbH member, professional service on demand , plugin development .
I don't answer to private message.
The topic has been locked.

Lime-years ahead

Online-surveys for every purse and purpose