- Posts: 103
- Thank you received: 1
Welcome to the LimeSurvey Community Forum
Ask the community, share ideas, and connect with other LimeSurvey users!
How to hide atributes that are not filled.
- Serafim
- Topic Author
- Offline
- Premium Member
Less
More
11 years 2 months ago #90661
by Serafim
How to hide atributes that are not filled. was created by Serafim
Hello,
is it possible to hide atributes in a token that are not filled? So when I use that atribute in a question, in the tokens that that atribute is filled it will show, but in tokens that atribute is not filled it does not appear.
Sorry for my english...
is it possible to hide atributes in a token that are not filled? So when I use that atribute in a question, in the tokens that that atribute is filled it will show, but in tokens that atribute is not filled it does not appear.
Sorry for my english...
The topic has been locked.
- tpartner
- Offline
- LimeSurvey Community Team
Less
More
- Posts: 10632
- Thank you received: 3696
11 years 2 months ago #90665
by tpartner
Cheers,
Tony Partner
Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
Replied by tpartner on topic How to hide atributes that are not filled.
With Expression Manager you can use an IF statement -
docs.limesurvey.org/Expression+Manager&s...mplemented_Functions
Code:
{if(TOKEN:ATTRIBUTE_5, TOKEN:ATTRIBUTE_5, '')}
Cheers,
Tony Partner
Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
The topic has been locked.
- Serafim
- Topic Author
- Offline
- Premium Member
Less
More
- Posts: 103
- Thank you received: 1
11 years 2 months ago #90675
by Serafim
Replied by Serafim on topic How to hide atributes that are not filled.
Thanks, I'm gonna try it.
The topic has been locked.
- Mazi
- Offline
- Official LimeSurvey Partner
11 years 2 months ago #90678
by Mazi
Best regards/Beste Grüße,
Dr. Marcel Minke
Need Help? We offer professional Limesurvey support: survey-consulting.com
Contact: marcel.minke(at)survey-consulting.com
Replied by Mazi on topic How to hide atributes that are not filled.
Tony, did you test that syntax? Doesn't it just test if the token attribute exists instead of checking whether it contains any value?
Anyway, if the above example doesn't work, try this:
Anyway, if the above example doesn't work, try this:
Code:
{if(!is_empty(TOKEN:ATTRIBUTE_5), TOKEN:ATTRIBUTE_5, '')}
Best regards/Beste Grüße,
Dr. Marcel Minke
Need Help? We offer professional Limesurvey support: survey-consulting.com
Contact: marcel.minke(at)survey-consulting.com
The topic has been locked.