Ask the community, share ideas, and connect with other LimeSurvey users!
To merge the results of linked surveys the most straight forward method is to use the automatically generated SAVEID of the first survey and transfer it via URL to the following surveys. That way you can use linked surveys even when not using tokens.I heard that you can also work with tokenized surveys, as long as the token tables of linked survey are identical. On second thought: I guess you only need a token table for the first survey and just pass the token to the second survey as a variable that is store somewhere. Later you have to combine the results tables based on the tokens. Have you ever used that?
www.limesurvey.org/manual/URL_fields/en#Basic_fieldsSAVEDID is the id assigned to this particular submission,
Sorry for confusion. You're right. I mean the response ID.tammo wrote: The surveyID is always the same when coming from survey1 (it is 111111). Do you mean the response ID, or am I missing something?
/* * *TOKEN REDIRECT * */ $(document).ready(function() { // Define the new message var redirect_text = 'Attendi mentre carichiamo le tue risposte.<br><img src=\"https://www.tbaf.org.tw/event/2016safe/imgs/loader1.gif\">'; // Insert the new message if($('#tokenmessage').length > 0) { if($('#tokenform').length > 0) { /*token messagge in ingresso, identifica la form dove inserire i numeri*/ } else { $('#tokenmessage').html(redirect_text); var url = "URL"; url += findToken(); //helper function to extract the token url += "/newtest/Y/lang/it"; //alert(url); window.location.replace(url); } } });
The redirection itself can be seen as an invalid action by security settings in the browser or antimalwaresecurity software. So you never have 100% when using survey redirection.Liod_DS wrote: Sometimes (I think 1 of 200-300 cases) a user can't get to the part2, and he remains stuck between the two surveys...did it happen to you too?
Thanks for the insight. Wonder if this script really copes with all situations then.tpartner wrote: Checking for the length of #tokenmessage and #tokenform tests to see if this is the token entry screen - these are elements found only in that screen.
/* funzione ad hoc per il recupero del token*/ function findToken() { var sPageURL = window.location.href; // alert(sPageURL); var sURLVariables = sPageURL.split('/'); for (var i = 0; i < sURLVariables.length; i++) { var sParameterName = sURLVariables[i]; if (sParameterName == "token") { return sURLVariables[i+1]; } } }