Welcome to the LimeSurvey Community Forum

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

Keywords on template

  • hribeiro
  • hribeiro's Avatar Topic Author
  • Offline
  • New Member
  • New Member
More
2 years 6 months ago #221012 by hribeiro
Keywords on template was created by hribeiro
Hi all,

I was planning echoing into save template the firstname of a user using the token. Is this possible on the 3.27 version? I've read a note saying this was deprecated but was unable to find the new method.

Thanks in advance
The topic has been locked.
  • holch
  • holch's Avatar
  • Away
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
2 years 6 months ago #221013 by holch
Replied by holch on topic Keywords on template
So you want to show the first name of the respondent in the survey, based on the name of the respondent's name saved in the token table? This is easily possible.

Now if you want to show it within the template, not within the survey (e.g. the welcome text or a question text), then I don't know.

Where did you read this note? This is always an important information to understand where you are coming from.

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.
  • DenisChenu
  • DenisChenu's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
2 years 6 months ago #221015 by DenisChenu
Replied by DenisChenu on topic Keywords on template
In github.com/LimeSurvey/LimeSurvey/blob/ma...ws/content/save.twig

You can use processString function.
{{ procressString("{TOKEN:FIRSTNAME}") }}

for example.

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 following user(s) said Thank You: tpartner
The topic has been locked.
  • hribeiro
  • hribeiro's Avatar Topic Author
  • Offline
  • New Member
  • New Member
More
2 years 6 months ago #221039 by hribeiro
Replied by hribeiro on topic Keywords on template
That's it! Perfect. Thank you Denis

Just a note for anyone who will copy paste: there's a typo so {{ processString("{TOKEN:FIRSTNAME}") }}
The following user(s) said Thank You: DenisChenu
The topic has been locked.

Lime-years ahead

Online-surveys for every purse and purpose