- Posts: 24
- Thank you received: 0
Welcome to the LimeSurvey Community Forum
Ask the community, share ideas, and connect with other LimeSurvey users!
Use variables (eg. username) in survey
- juppix
- Topic Author
- Offline
- Junior Member
Less
More
5 years 6 months ago #174584
by juppix
Use variables (eg. username) in survey was created by juppix
Hi all,
I want to create a pesonalized welcome page. Something like:
"Welcome {username}!"
Is it possible to use variables from the attendees list?
user firstname, lastname, email...
thanks
jup
I want to create a pesonalized welcome page. Something like:
"Welcome {username}!"
Is it possible to use variables from the attendees list?
user firstname, lastname, email...
thanks
jup
The topic has been locked.
- holch
- Offline
- LimeSurvey Community Team
Less
More
- Posts: 11658
- Thank you received: 2742
5 years 6 months ago #174585
by holch
I answer at the LimeSurvey forum in my spare time, I'm not a LimeSurvey GmbH employee.
No support via private message.
Replied by holch on topic Use variables (eg. username) in survey
Have a look at the participant table, tokens and custom attributes.
You can create custom attributes, upload the list as CSV and display these custom attributes via expression manager in the survey.
Have a look at micro tayloring in the manual regarding the expression manager.
You can create custom attributes, upload the list as CSV and display these custom attributes via expression manager in the survey.
Have a look at micro tayloring in the manual regarding the expression manager.
I answer at the LimeSurvey forum in my spare time, I'm not a LimeSurvey GmbH employee.
No support via private message.
The following user(s) said Thank You: juppix
The topic has been locked.
- juppix
- Topic Author
- Offline
- Junior Member
Less
More
- Posts: 24
- Thank you received: 0
5 years 6 months ago #174587
by juppix
Replied by juppix on topic Use variables (eg. username) in survey
Great! But is it also possible to use this variables as prefilled answers? As a proposed answer?
The topic has been locked.
- holch
- Offline
- LimeSurvey Community Team
Less
More
- Posts: 11658
- Thank you received: 2742
5 years 6 months ago #174588
by holch
I answer at the LimeSurvey forum in my spare time, I'm not a LimeSurvey GmbH employee.
No support via private message.
Replied by holch on topic Use variables (eg. username) in survey
What do you mean with "prefilled answer", proposed answer?
Do you mean e.g. number of children. You have the number of children in the database, so you want to put this as the default answer? This is also possible, but depends a little bit on the question type you are using.
Do you mean e.g. number of children. You have the number of children in the database, so you want to put this as the default answer? This is also possible, but depends a little bit on the question type you are using.
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.
- juppix
- Topic Author
- Offline
- Junior Member
Less
More
- Posts: 24
- Thank you received: 0
5 years 6 months ago #174589
by juppix
Replied by juppix on topic Use variables (eg. username) in survey
Yes ! I mean this!
Could you explain your answer a bit?
Could you explain your answer a bit?
The topic has been locked.
- juppix
- Topic Author
- Offline
- Junior Member
Less
More
- Posts: 24
- Thank you received: 0
5 years 6 months ago #174591
by juppix
Replied by juppix on topic Use variables (eg. username) in survey
Okay. I tried it and it works.
BUT: I want that users can reopen their survey and change the informations filled in before.
Now, if I use a {TOKEN:FIRSTNAME} as suggested answer, I would get always the info from the database.
Is it possible to check wether the user answered this question before? if so there should appear the user input text - not the database text.
you know what I mean?
BUT: I want that users can reopen their survey and change the informations filled in before.
Now, if I use a {TOKEN:FIRSTNAME} as suggested answer, I would get always the info from the database.
Is it possible to check wether the user answered this question before? if so there should appear the user input text - not the database text.
you know what I mean?
The topic has been locked.
- jelo
- Offline
- Platinum Member
Less
More
- Posts: 5033
- Thank you received: 1257
5 years 6 months ago #174593
by jelo
The meaning of the word "stable" for users
www.limesurvey.org/forum/development/117...ord-stable-for-users
Replied by jelo on topic Use variables (eg. username) in survey
You will need to use ExpressionManager (which is a Script language, soon called ExpressionScript).
But depending on the questions, where you want to assign default values, it might be a bit tricky.
If the question has a default answer value, you might check via is_empty on the fieldcontent.
Can you provide a simple survey as an example (lss export)?
But depending on the questions, where you want to assign default values, it might be a bit tricky.
If the question has a default answer value, you might check via is_empty on the fieldcontent.
Can you provide a simple survey as an example (lss export)?
The meaning of the word "stable" for users
www.limesurvey.org/forum/development/117...ord-stable-for-users
The topic has been locked.
- DenisChenu
- Offline
- LimeSurvey Community Team
Less
More
- Posts: 13643
- Thank you received: 2491
5 years 6 months ago #174595
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.
Replied by DenisChenu on topic Use variables (eg. username) in survey
For last name etc (text question), directly use {TOKEN:LASTNAME} in default value.
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.
- juppix
- Topic Author
- Offline
- Junior Member
Less
More
- Posts: 24
- Thank you received: 0
5 years 6 months ago #174598
by juppix
Replied by juppix on topic Use variables (eg. username) in survey
Okay... please find the file attached
Attachments:
The topic has been locked.
- juppix
- Topic Author
- Offline
- Junior Member
Less
More
- Posts: 24
- Thank you received: 0
5 years 6 months ago #174631
by juppix
Replied by juppix on topic Use variables (eg. username) in survey
Hi !
I tried everything - no result
My formula:
{if(is_empty(kontaktinfos.SQ001),"",{TOKEN:ATTRIBUTE_8})}
I tried everything - no result
My formula:
{if(is_empty(kontaktinfos.SQ001),"",{TOKEN:ATTRIBUTE_8})}
The topic has been locked.
- DenisChenu
- Offline
- LimeSurvey Community Team
Less
More
- Posts: 13643
- Thank you received: 2491
5 years 6 months ago #174632
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.
Replied by DenisChenu on topic Use variables (eg. username) in survey
Because it must be
{if(is_empty(kontaktinfos.SQ001),TOKEN:ATTRIBUTE_8,kontaktinfos.SQ001)}
in an equation question type
But : use manual.limesurvey.org/Default_answers for short text
{if(is_empty(kontaktinfos.SQ001),TOKEN:ATTRIBUTE_8,kontaktinfos.SQ001)}
in an equation question type
But : use manual.limesurvey.org/Default_answers for short text
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.
- juppix
- Topic Author
- Offline
- Junior Member
Less
More
- Posts: 24
- Thank you received: 0
5 years 6 months ago #174651
by juppix
Replied by juppix on topic Use variables (eg. username) in survey
Attachments:
The topic has been locked.