Welcome to the LimeSurvey Community Forum

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

Probs with pre-select

  • svenjalell
  • svenjalell's Avatar Topic Author
  • Offline
  • New Member
  • New Member
More
2 years 9 months ago - 2 years 9 months ago #218173 by svenjalell
Probs with pre-select was created by svenjalell
Hi all,

lately I've created a survey, the participants can only access with a token. The url is similar to
 
example.org/index.php/123456?token=moinmoin&lang=de

Now I want to to preseelect the first the answer to the first question, which is a single request according to

manual.limesurvey.org/URL_fields (you may search for " ls.example.org/1234?1234X1X1SQ001=A1 " )

So I tried the following:

example.org/index.php/123456?token=moinm...=de&123456X22X3F0=A1

For question data please see Attachments.


However it never worked.

Can you get me started here ?

Moreover I'd like to know wether to read by Expression script and create a condition like say
if tokenstring startswith "t" let the answer to  singleselectquestion F0 = A1. possible ? or similar ?


Thanks for your feedback!


Best,
Svenja
Last edit: 2 years 9 months ago by DenisChenu. Reason: Usage of example.org !
The topic has been locked.
  • tpartner
  • tpartner's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
2 years 9 months ago - 2 years 9 months ago #218180 by tpartner
Replied by tpartner on topic Probs with pre-select
Regarding the first question, you need to use either the SGQA OR the question code. You have mixed them together.


Code:
https://example.org/index.php/123456?token=moinmoin&lang=de&123456X3X22=A1
OR
[code]https://example.org/index.php/123456?token=moinmoin&lang=de&F0=A1
 
Regarding the second question, yes, you can set the question via the ExpressionScript assignment operator in an equation type question - https://manual.limesurvey.org/ExpressionScript_-_Presentation#Caution_about_using_Assignment_Operator_.28.3D.29
[/code]

Cheers,
Tony Partner

Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
Last edit: 2 years 9 months ago by tpartner.
The topic has been locked.
  • svenjalell
  • svenjalell's Avatar Topic Author
  • Offline
  • New Member
  • New Member
More
2 years 9 months ago #218203 by svenjalell
Replied by svenjalell on topic Probs with pre-select
Hi,
this is very helpful...
Basically we have distinct subgroups. We want to present them the same questionaire and distinguishing between different subgroups of participants in the background. So they should not see which group they belong to.

My idea was to create a questionaire-url that has a parameter which preselects a value in a question that refers to the subgroup. With the parameter I mentioned in the first posting it already works (thanks for your help btw!). The prob is, that if we hide the question in the lime survey backend it never gets any values.

Can you show me a way how to assign the participants to a group invisibly to them ?

Thanks!

Best,
Svenja
The topic has been locked.
  • DenisChenu
  • DenisChenu's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
2 years 9 months ago #218204 by DenisChenu
Replied by DenisChenu on topic Probs with pre-select
I don't understand : how you know group ?
If you know group when create token : why not use Token attribute ?

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.
  • svenjalell
  • svenjalell's Avatar Topic Author
  • Offline
  • New Member
  • New Member
More
2 years 9 months ago - 2 years 9 months ago #218207 by svenjalell
Replied by svenjalell on topic Probs with pre-select
Hi,

we know the group when create token. But we want to offer a similar link to everyone like for instance:
example.org/index.php/123456?token=moinmoin&lang=de

But this would lead to resultset, where each line would represent a participation trial. How can we know, to which group we can assign each trial ?

Sorry for the questions we are right at the beginning... Maybe we need a different way...
Last edit: 2 years 9 months ago by svenjalell.
The topic has been locked.
  • tpartner
  • tpartner's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
2 years 9 months ago #218210 by tpartner
Replied by tpartner on topic Probs with pre-select

The prob is, that if we hide the question in the lime survey backend it never gets any values.

Hiding the question should not matter. What LS version are you using? How are you hiding the question?

Cheers,
Tony Partner

Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
The topic has been locked.
  • DenisChenu
  • DenisChenu's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
2 years 9 months ago #218214 by DenisChenu
Replied by DenisChenu on topic Probs with pre-select

Hi,

we know the group when create token. But we want to offer a similar link to everyone like for instance:
example.org/index.php/123456?token=moinmoin&lang=de

 
I still don't understand ?

You want to use token or not ? You want to use same token for all user ?

And again : Why not use participant attribute ?
 

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.
  • svenjalell
  • svenjalell's Avatar Topic Author
  • Offline
  • New Member
  • New Member
More
2 years 9 months ago #218222 by svenjalell
Replied by svenjalell on topic Probs with pre-select
Hi,
yes we want to use tokens. Each user receives his own token.

... not sure how to deal with the participant attribute and where to find it ... sorry...
The topic has been locked.
  • svenjalell
  • svenjalell's Avatar Topic Author
  • Offline
  • New Member
  • New Member
More
2 years 9 months ago #218223 by svenjalell
Replied by svenjalell on topic Probs with pre-select
Hi,
... managed to hide a question via the custom.css of the theme... works for me.
The topic has been locked.
  • DenisChenu
  • DenisChenu's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
2 years 9 months ago #218224 by DenisChenu
Replied by DenisChenu on topic Probs with pre-select

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.
  • svenjalell
  • svenjalell's Avatar Topic Author
  • Offline
  • New Member
  • New Member
More
2 years 9 months ago #218231 by svenjalell
Replied by svenjalell on topic Probs with pre-select
Hi Denis,
thx a lot...
... came across this also... but this does not work for anonymous polls? Is it possible to put the to put the token in the result matrix ? So with the token added in each line you may see which group the participant belongs ?

Best,
Svenja
The topic has been locked.
  • DenisChenu
  • DenisChenu's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
2 years 9 months ago #218232 by DenisChenu
Replied by DenisChenu on topic Probs with pre-select
OK,
Right : no way with anonymous survey.

You can use it in email (to add the Q01={ATTRIBUTE_1}) 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 topic has been locked.

Lime-years ahead

Online-surveys for every purse and purpose