Welcome to the LimeSurvey Community Forum

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

How to add expression manager data to mailto link in LimeSurvey

  • KoenraadV94
  • KoenraadV94's Avatar Topic Author
  • Offline
  • New Member
  • New Member
More
2 years 9 months ago #217001 by KoenraadV94
Hi,

For a survey I am working on, I am looking for an easy way for respondents to contact me. In many of the answers to questions I have made (radio button questions), I have inserted mailto links, with a reference to the question in the body of the mail. The answer itself is an option that states that the respondent would like help with this question.

The survey is quite long (it is very well possible that respondents will fill it out over multiple days), so I'd like to receive the mail when they have an issue without having to wait until they submit the survey.

I would also like to add data of the participant in the mail. I've tried the following code: <a href="mailto:test@mail.com?subject={​TOKEN:FIRSTNAME}​​​​​​​​"/>. Unfortunately in practice the link will literally insert {TOKEN:FIRSTNAME} into the subject of the mail.

Am I missing something or is there another way to resolve this problem? I'd like to have one mail per issue, so using one of the admin notification mails to inform me that the respondent has answered that he'd like help with a question wouldn't be the most practical solution to my issue.

Thanks in advance for your help!
The topic has been locked.
  • tpartner
  • tpartner's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
2 years 9 months ago #217010 by tpartner
LimeSurvey version?

Are tokens activated?

What do you see in the link when you view the source of the survey page?

Cheers,
Tony Partner

Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
The following user(s) said Thank You: DenisChenu
The topic has been locked.
  • KoenraadV94
  • KoenraadV94's Avatar Topic Author
  • Offline
  • New Member
  • New Member
More
2 years 9 months ago - 2 years 9 months ago #217017 by KoenraadV94
Hi Tony,

Thank you for your quick response.

- The version number is 3.22.28+200728
- Tokens are indeed activated
- In the source code I see the following (latest test) <a href="mailto:koenraadv94@gmail.com?subject=Test2&amp;body=%7BTOKEN%3AEMAIL%7D%20test2">Contact us

Please let me know if I forgot any information that you would need.

Thanks again!
Last edit: 2 years 9 months ago by KoenraadV94.
The topic has been locked.
  • Joffm
  • Joffm's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
2 years 9 months ago - 2 years 9 months ago #217022 by Joffm
Hi,
just one thing to mention:
Did you consider to implement a chat system like  Livehelperchat  if you think you need an option to ask for help in (nearly) any question?

Joffm

Volunteers are not paid.
Not because they are worthless, but because they are priceless
Last edit: 2 years 9 months ago by Joffm.
The topic has been locked.
  • tpartner
  • tpartner's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
2 years 9 months ago #217042 by tpartner
This maybe caused by the HTML editor "fixing" the code.

Try setting the editor to "pop-up" so it opens in source mode.

Cheers,
Tony Partner

Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
The topic has been locked.
  • KoenraadV94
  • KoenraadV94's Avatar Topic Author
  • Offline
  • New Member
  • New Member
More
2 years 9 months ago #217084 by KoenraadV94
Hi Joffm,

Thank you for your suggestion! I haven't considered it, but I'll look into it. My preference would probably still be a mail in order to have an easier overview of respondents in need of extra explanation, but I will definitely look into this.

Thanks again!
The topic has been locked.
  • KoenraadV94
  • KoenraadV94's Avatar Topic Author
  • Offline
  • New Member
  • New Member
More
2 years 9 months ago #217087 by KoenraadV94
Hi Tony,

Thank you for the suggestion. I'm not entirely sure whether I understand correctly. Is this is a setting so that the editor starts in the mode where I can edit source code? If so, where exactly can I find it? I've looked, but I cannot seem to find it yet.

Kind regards,

Koen
The topic has been locked.
  • Joffm
  • Joffm's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
2 years 9 months ago #217089 by Joffm
Hi, Koen,

you find it here in "Global Settings / General"
 

There are three options:
1. Embedded
 
Here you have a button "source" to switch to source code.
And this editor sometimes has his own ideas how to deal with some things.

2. Popup
 
You start in source code mode, but a click on the pencil on the right opens the WYSIWYG editor in a popup window.
 

3. HTML source code
 
Plain HTML source code.

Best regards
Joffm

Volunteers are not paid.
Not because they are worthless, but because they are priceless
The topic has been locked.
  • KoenraadV94
  • KoenraadV94's Avatar Topic Author
  • Offline
  • New Member
  • New Member
More
2 years 9 months ago #217115 by KoenraadV94
Hi Joffm and Tony,

I just tried this setting, but unfortunately without success. I did notice that in the HTML tag the code automatically gets adjusted, so the curly braces aren't literally in there (<a href="mailto:testadress@gmail.com?subject=%7BTOKEN%3AEMAIL%7D&amp;body=%7BTOKEN%3AEMAIL%7D">NewTest), but I suppose that won't be the cause of this issue?

Thanks again!

Kind regards,

Koen
The topic has been locked.
  • holch
  • holch's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
2 years 9 months ago #217117 by holch
That is exactly the cause of this issue. The editor is changing the curly braces.

Switch off the editor and it should be no problem anymore.

I answer at the LimeSurvey forum in my spare time, I'm not a LimeSurvey GmbH employee.
No support via private message.

The topic has been locked.
  • KoenraadV94
  • KoenraadV94's Avatar Topic Author
  • Offline
  • New Member
  • New Member
More
2 years 9 months ago #217191 by KoenraadV94
Hi Holch,

Where can I turn off this setting specifically? I wasn't able to find this setting.

Thanks again.

Kind regards,

Koen
The topic has been locked.
  • holch
  • holch's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
2 years 9 months ago #217199 by holch
Come on, did you read all the posts?!

Joffm posted this days ago:

Hi, Koen,

you find it here in "Global Settings / General"
ScreenShot_20210609103731.jpeg


You can also set this on a user level in your user account, afaik. But if someone else opens in the editor, it might have the same result.

I answer at the LimeSurvey forum in my spare time, I'm not a LimeSurvey GmbH employee.
No support via private message.

The topic has been locked.

Lime-years ahead

Online-surveys for every purse and purpose