Welcome to the LimeSurvey Community Forum

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

Recording/allowing respondent IDs from external website

More
3 years 7 months ago #223836 by DenisChenu
Best seem to rename your params to userID and create a question with title userID.

Else : when testing : allways use another clean browser : we don't update current test with a link. You can add &newtest=Y to the link to be sure to test on a clean response.

Assistance on LimeSurvey forum and LimeSurvey core development are on my free time.
I'm not a LimeSurvey GmbH member. - Professional support - Plugins, theme and development .
I don't answer to private message.

Please Log in to join the conversation.

More
3 years 4 months ago #226876 by lotta_fox
Hey everyone, 
I would like to broad this subject again as I have the same or a similar issue with clickworker. I added the variable for the panel integration and when I tested it myself, it worked. However, I now test it with a small sample size from clickworker and the ID is not passed on the respective variable (or any other, of course).
I assume the issue is that lime survey needs the URL extension in this form: &user_id="userID" but clickworker adds it this way &user_id=userID. I contacted clickworker regarding this problem but they said they are not able to change the URL extension to the needed format.Has anyone an idea if I can enable the ID disclosure with the URL extension in the clickworker format?I also have added the LSS of the respective survey. My storing question for the ID is ID.

Thanks in advance and best regards Lotta

File Attachment:

File Name: limesurvey... (2).lss
File Size:190.94 KB

Please Log in to join the conversation.

More
3 years 4 months ago #226879 by tpartner
There should be no quotes in the URL parameters.

Can you attach a screenshot of your panel integration screen?

Cheers,
Tony Partner

Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.

Please Log in to join the conversation.

More
3 years 4 months ago - 3 years 4 months ago #226880 by lotta_fox
Thanks for the quick response. I am not 100% sure to which screen you refer to. I hope I added the screenshot you need:



Best regards

Lotta

 

 
Last edit: 3 years 4 months ago by lotta_fox.

Please Log in to join the conversation.

More
3 years 4 months ago - 3 years 4 months ago #226882 by Joffm
Hi,

needs the URL extension in this form: &user_id="userID"

No, without quotes.

And I do not see an issue at all.

With this url:

www.myServer.de/limesurvey/index.php/396...Fitzliputzli-Tralala


I got this
 
Tested in 3.27.33

By the way:
Which LimeSurvey version are you using?
Looking at the lss export I see a database version of 261, which seems to be rather old.

Joffm

Volunteers are not paid.
Not because they are worthless, but because they are priceless
Last edit: 3 years 4 months ago by Joffm. Reason: Image inserted

Please Log in to join the conversation.

More
3 years 4 months ago #226884 by lotta_fox
Hey @Joffm,
so you think my problem might occur because my lime survey version (Version 2.62.2+170203) is outdated? I use the one provided by my university.
Currently the panel integration URL does not work at all in my version.

Best regards

Lotta

Please Log in to join the conversation.

More
3 years 4 months ago #226888 by Joffm
Well, generally, it is. It is more than 5 years old without security fixes.

But this shouldn't be the problem.
Because my "old" version 2.73.1. wasn't at hand I tested in version 3.x. 

But here in 2.73.1.
 

Joffm

You can always try to do it without "panel integration".
Rename the question to "userid" and call the survey with ...?lang=en&userid=Tralali und Tralala
 

Volunteers are not paid.
Not because they are worthless, but because they are priceless

Please Log in to join the conversation.

More
3 years 4 months ago #226889 by tammo
Rename the question to "userid" and call the survey with ...?lang=en&userid=Tralali und Tralala

But then without spaces, I think?


Tammo ter Hark at Respondage
For Limesurvey reporting, education and customized themes
respondage.nl

Please Log in to join the conversation.

More
3 years 4 months ago #226892 by tpartner
I think the problem is that the panel refuses to use anything except "user_id" as a parameter name. This won't work as a question ID due to the underscore.

Here is a solution I used before panel integration existed...

Place this script in the source of a short-text question.

The script will:

1) Hide the short-text question.
2) Load the user_id URL parameter value into the text input.

This will only work if the welcome message is not used and the short-text question is in the first survey screen (group).

Code:
<script type="text/javascript" data-author="Tony Partner">  
  $(document).on('ready pjax:scriptcomplete',function(){
 
    // Hide this question
    $('#question{QID}').hide
 
    // Load the 'user_id' value from the URL
    var uid = getURLParameter('user_id');
    $('#question{QID} input:text').val(uid);
 
  });
 
  function getURLParameter(name) {
    return decodeURI(
      (RegExp(name + '=' + '(.+?)(&amp;|$)').exec(location.search)||[,null])[1]
    );
  }
</script>

Cheers,
Tony Partner

Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.

Please Log in to join the conversation.

More
3 years 4 months ago #226893 by lotta_fox
Thanks @joffm, @tammo and @tpartner for your answers and your solutions. 

Indeed, userid would not work, since clickworkers only works with the parameter user_id. 
What I have tried in the meanwhile and what for any reason worked was:
  1. I copied my survey, 
  2. I deleted my ID question and created a new one
  3. and (most important) I disabled the Recaptcha from my survey.
For any reason the passthrough does not work when I use a Recaptcha. I will try it with my original survey an the life setting tomorrow and keep you posted if this is a helpful solution. Otherwise, I will go with tpartners solution (finger crossed). 

Thanks and best regards

Lotta

Please Log in to join the conversation.

More
3 years 4 months ago #226894 by holch
Usually these things don't work if the question with the attribute is not on the first page of your survey (captcha, welcome text, etc.). Basically the URL changes after the first page has opened and then the ID is gone.

Help us to help you!
  • Provide your LS version and where it is installed (own server, uni/employer, SaaS hosting, etc.).
  • Always provide a LSS file (not LSQ or LSG).
Note: I answer at this forum in my spare time, I'm not a LimeSurvey GmbH employee.

Please Log in to join the conversation.

More
3 years 4 months ago #226912 by Joffm
What I showed successfully was with the captcha and the welcome screen.
video follows.
Tested in Chrome, Firefox and Edge.

@tammo: No with spaces, as you see in the "Haus vom Nikolaus" example.

But as I said: I tested in 2.73.1. and she uses 2.62.2.

Anyway, you have some alternatives to try.

Joffm
 

Volunteers are not paid.
Not because they are worthless, but because they are priceless

Please Log in to join the conversation.

More
3 years 4 months ago #226918 by lotta_fox
Yes, it workes for me with the welcome page but not with a captcha. However, to be sure I disabled the welcome page and it works in the life session with clickworker but for any reason I have cases with and cases without an ID passed through. I assume this is sth. I have to discuss with clickwork. 
I might also a bug in my first questionnaire version which dissolved when copying the survey. 

Thanks all for your help, solutions and time

 

Please Log in to join the conversation.

Moderators: holchtpartner

Lime-years ahead

Online-surveys for every purse and purpose