Script ID not coming through with query parameters


Author
Message
Dave
Dave
Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)
Group: Administrators
Posts: 13K, Visits: 104K
amomen425 - Friday, December 21, 2018

Sorry for the late replay, I've been on leave from school. I tried the code and it worked! Thank you so much.
In regards to the '&id=%SURVEY_CODE%' query parameter, I use it to capture the anonymous codes university students are assigned when they open my survey through the university's online platform (perhaps you've heard of it, it's called 'SONA') so that when they are redirected back to that website after participating, they are automatically given credit for participating in my study, as explained in this website: https://www.sona-systems.com/help/qualtrics.aspx.

Ah, thank you for the explanation re. the %SURVEY_CODE% placeholder. If you ever need to set up interfacing between Inquisit Web and SONA (i.e. something like SONA -> Inquisit Web -> Qualtrics -> SONA for crediting), note that the instructions pertaining to Inquisit Web provided by SONA are more complicated and make things more fragile than they need to be. I've described a more straightforward way here:

https://www.millisecond.com/forums/FindPost26186.aspx

amomen425
amomen425
Esteemed Member (1.7K reputation)Esteemed Member (1.7K reputation)Esteemed Member (1.7K reputation)Esteemed Member (1.7K reputation)Esteemed Member (1.7K reputation)Esteemed Member (1.7K reputation)Esteemed Member (1.7K reputation)Esteemed Member (1.7K reputation)Esteemed Member (1.7K reputation)
Group: Forum Members
Posts: 21, Visits: 99
Dave - Friday, December 14, 2018
amomen425 - Friday, December 14, 2018
Dave - Friday, December 14, 2018
amomen425 - Friday, December 14, 2018
I always used to be able to get the participant ID using query parameters, but, now as you can see (image of csv data sheet attached), inquisit spits out these weird characters. I don't think I am doing anything wrong since every so often it spits the correct participant ID (i.e., '240'). What to do?

https://www.millisecond.com/forums/Uploads/Images/7c52e4f8-c398-4472-8890-03da.png

It's not possible to say where / what the issue may be without seeing the actual set up of the web script. Would it be possible to share the link to the experiment's start page here, please?

Of course.
Here is the link: https://mili2nd.co/2clb

Thanks for the link. Given how things are set up, I assume you have participants start with Inquisit and then want to redirect them from there to a Qualtrics survey, passing the subject number randomly generated by Inquisit over to Qualtrics. Is that correct or is there some other component prior to the Inquisit Web part?

If not, the setup looks generally okay, although there is one thing that doesn't quite seem right. You've indicated

https://gmuchss.qualtrics.com/jfe/form/SV_bJaXzG9gIVmPNWZ?subjectid=<%script.subjectid%>&id=%SURVEY_CODE%

as the URL to redirect to in your web experiment's settings. Now, the bolded part is not something Inquisit knows about and would just produce garble (there is no such thing as a %SURVEY_CODE% placeholder / variable in Inquisit). Where is that coming from and what is the purpose?

At any rate, there is an alternative way to specify a URL for redirection, and whether that resolves the problem (although I'm unable to reproduce it) is worth trying. You can have your script set the redirection directly instead of putting it in the web settings, i.e, you can do

<text finishURL>
/ items = ("https://gmuchss.qualtrics.com/jfe/form/SV_bJaXzG9gIVmPNWZ?subjectid=<%script.subjectid%>")
</text>

or

<text finishURL>
/ items = ("https://gmuchss.qualtrics.com/jfe/form/SV_bJaXzG9gIVmPNWZ?subjectid=<%script.subjectid%>&id=%SURVEY_CODE%")
</text>

(if the id / SURVEY_CODE parameter needs to be there for some reason, although Inquisit won't be able to do anything with it)

with

<expt>
/ onexptbegin = [
defaults.finishpage = text.finishURL.item(1);
]


/ onexptbegin = [
list.human_uprightitems_repeatedupright.appenditem(list.nitems.nextindex);
list.human_uprightitems_repeatedupright.appenditem(list.nitems.nextindex);
list.human_uprightitems_repeatedupright.appenditem(list.nitems.nextindex);
list.human_uprightitems_repeatedupright.appenditem(list.nitems.nextindex);
list.human_uprightitems_repeatedupright.appenditem(list.nitems.nextindex);
list.human_uprightitems_repeatedupright.appenditem(list.nitems.nextindex);
list.human_uprightitems_repeatedupright.appenditem(list.nitems.nextindex);
list.human_uprightitems_repeatedupright.appenditem(list.nitems.nextindex);
list.human_uprightitems_repeatedupright.appenditem(list.nitems.nextindex);
list.human_uprightitems_repeatedupsidedown.appenditem(list.nitems.nextindex);
list.human_uprightitems_repeatedupsidedown.appenditem(list.nitems.nextindex);
list.human_uprightitems_repeatedupsidedown.appenditem(list.nitems.nextindex);
list.human_uprightitems_repeatedupsidedown.appenditem(list.nitems.nextindex);
list.human_uprightitems_repeatedupsidedown.appenditem(list.nitems.nextindex);
list.human_uprightitems_repeatedupsidedown.appenditem(list.nitems.nextindex);
list.human_uprightitems_repeatedupsidedown.appenditem(list.nitems.nextindex);
list.human_uprightitems_repeatedupsidedown.appenditem(list.nitems.nextindex);
list.human_uprightitems_repeatedupsidedown.appenditem(list.nitems.nextindex);

list.android_uprightitems_repeatedupright.appenditem(list.nitems.nextindex);
list.android_uprightitems_repeatedupright.appenditem(list.nitems.nextindex);
list.android_uprightitems_repeatedupright.appenditem(list.nitems.nextindex);
list.android_uprightitems_repeatedupright.appenditem(list.nitems.nextindex);
list.android_uprightitems_repeatedupright.appenditem(list.nitems.nextindex);
list.android_uprightitems_repeatedupright.appenditem(list.nitems.nextindex);
list.android_uprightitems_repeatedupright.appenditem(list.nitems.nextindex);
list.android_uprightitems_repeatedupright.appenditem(list.nitems.nextindex);
list.android_uprightitems_repeatedupright.appenditem(list.nitems.nextindex);
list.android_uprightitems_repeatedupsidedown.appenditem(list.nitems.nextindex);
list.android_uprightitems_repeatedupsidedown.appenditem(list.nitems.nextindex);
list.android_uprightitems_repeatedupsidedown.appenditem(list.nitems.nextindex);
list.android_uprightitems_repeatedupsidedown.appenditem(list.nitems.nextindex);
list.android_uprightitems_repeatedupsidedown.appenditem(list.nitems.nextindex);
list.android_uprightitems_repeatedupsidedown.appenditem(list.nitems.nextindex);
list.android_uprightitems_repeatedupsidedown.appenditem(list.nitems.nextindex);
list.android_uprightitems_repeatedupsidedown.appenditem(list.nitems.nextindex);
list.android_uprightitems_repeatedupsidedown.appenditem(list.nitems.nextindex);

list.upright_test_items.appenditem(list.nitems.nextindex);
list.upright_test_items.appenditem(list.nitems.nextindex);
list.upright_test_items.appenditem(list.nitems.nextindex);
list.upright_test_items.appenditem(list.nitems.nextindex);
list.upright_test_items.appenditem(list.nitems.nextindex);
list.upright_test_items.appenditem(list.nitems.nextindex);
list.upright_test_items.appenditem(list.nitems.nextindex);
list.upright_test_items.appenditem(list.nitems.nextindex);
list.upright_test_items.appenditem(list.nitems.nextindex);
list.upright_test_items.appenditem(list.nitems.nextindex);
list.upright_test_items.appenditem(list.nitems.nextindex);
list.upright_test_items.appenditem(list.nitems.nextindex);
list.upright_test_items.appenditem(list.nitems.nextindex);
list.upright_test_items.appenditem(list.nitems.nextindex);
list.upright_test_items.appenditem(list.nitems.nextindex);
list.upright_test_items.appenditem(list.nitems.nextindex);
list.upright_test_items.appenditem(list.nitems.nextindex);
list.upright_test_items.appenditem(list.nitems.nextindex);


list.upside_down_test_items.appenditem(list.nitems.nextindex);
list.upside_down_test_items.appenditem(list.nitems.nextindex);
list.upside_down_test_items.appenditem(list.nitems.nextindex);
list.upside_down_test_items.appenditem(list.nitems.nextindex);
list.upside_down_test_items.appenditem(list.nitems.nextindex);
list.upside_down_test_items.appenditem(list.nitems.nextindex);
list.upside_down_test_items.appenditem(list.nitems.nextindex);
list.upside_down_test_items.appenditem(list.nitems.nextindex);
list.upside_down_test_items.appenditem(list.nitems.nextindex);
list.upside_down_test_items.appenditem(list.nitems.nextindex);
list.upside_down_test_items.appenditem(list.nitems.nextindex);
list.upside_down_test_items.appenditem(list.nitems.nextindex);
list.upside_down_test_items.appenditem(list.nitems.nextindex);
list.upside_down_test_items.appenditem(list.nitems.nextindex);
list.upside_down_test_items.appenditem(list.nitems.nextindex);
list.upside_down_test_items.appenditem(list.nitems.nextindex);
list.upside_down_test_items.appenditem(list.nitems.nextindex);
list.upside_down_test_items.appenditem(list.nitems.nextindex);



]

/ blocks = [
1 = intro_Attention_Check;
2 = intro_1;
3 = intro_2;
4 = intro_3;
5 = intro_4;
6 = intro_6;
7 = intro_7;
8 = intro_8;
9 = intro_5;
10 = human_android_upright;
11 = testingphase;
12 = human_android_test]

</expt>

I've attached a version of your script that does that -- please give this a shot at your earliest convenience and let me know if it makes any difference as far as the transfer of the subject ID is concerned.

Sorry for the late replay, I've been on leave from school. I tried the code and it worked! Thank you so much.
In regards to the '&id=%SURVEY_CODE%' query parameter, I use it to capture the anonymous codes university students are assigned when they open my survey through the university's online platform (perhaps you've heard of it, it's called 'SONA') so that when they are redirected back to that website after participating, they are automatically given credit for participating in my study, as explained in this website: https://www.sona-systems.com/help/qualtrics.aspx.
Dave
Dave
Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)
Group: Administrators
Posts: 13K, Visits: 104K
amomen425 - Friday, December 14, 2018
Dave - Friday, December 14, 2018
amomen425 - Friday, December 14, 2018
I always used to be able to get the participant ID using query parameters, but, now as you can see (image of csv data sheet attached), inquisit spits out these weird characters. I don't think I am doing anything wrong since every so often it spits the correct participant ID (i.e., '240'). What to do?

https://www.millisecond.com/forums/Uploads/Images/7c52e4f8-c398-4472-8890-03da.png

It's not possible to say where / what the issue may be without seeing the actual set up of the web script. Would it be possible to share the link to the experiment's start page here, please?

Of course.
Here is the link: https://mili2nd.co/2clb

Thanks for the link. Given how things are set up, I assume you have participants start with Inquisit and then want to redirect them from there to a Qualtrics survey, passing the subject number randomly generated by Inquisit over to Qualtrics. Is that correct or is there some other component prior to the Inquisit Web part?

If not, the setup looks generally okay, although there is one thing that doesn't quite seem right. You've indicated

https://gmuchss.qualtrics.com/jfe/form/SV_bJaXzG9gIVmPNWZ?subjectid=<%script.subjectid%>&id=%SURVEY_CODE%

as the URL to redirect to in your web experiment's settings. Now, the bolded part is not something Inquisit knows about and would just produce garble (there is no such thing as a %SURVEY_CODE% placeholder / variable in Inquisit). Where is that coming from and what is the purpose?

At any rate, there is an alternative way to specify a URL for redirection, and whether that resolves the problem (although I'm unable to reproduce it) is worth trying. You can have your script set the redirection directly instead of putting it in the web settings, i.e, you can do

<text finishURL>
/ items = ("https://gmuchss.qualtrics.com/jfe/form/SV_bJaXzG9gIVmPNWZ?subjectid=<%script.subjectid%>")
</text>

or

<text finishURL>
/ items = ("https://gmuchss.qualtrics.com/jfe/form/SV_bJaXzG9gIVmPNWZ?subjectid=<%script.subjectid%>&id=%SURVEY_CODE%")
</text>

(if the id / SURVEY_CODE parameter needs to be there for some reason, although Inquisit won't be able to do anything with it)

with

<expt>
/ onexptbegin = [
defaults.finishpage = text.finishURL.item(1);
]


/ onexptbegin = [
list.human_uprightitems_repeatedupright.appenditem(list.nitems.nextindex);
list.human_uprightitems_repeatedupright.appenditem(list.nitems.nextindex);
list.human_uprightitems_repeatedupright.appenditem(list.nitems.nextindex);
list.human_uprightitems_repeatedupright.appenditem(list.nitems.nextindex);
list.human_uprightitems_repeatedupright.appenditem(list.nitems.nextindex);
list.human_uprightitems_repeatedupright.appenditem(list.nitems.nextindex);
list.human_uprightitems_repeatedupright.appenditem(list.nitems.nextindex);
list.human_uprightitems_repeatedupright.appenditem(list.nitems.nextindex);
list.human_uprightitems_repeatedupright.appenditem(list.nitems.nextindex);
list.human_uprightitems_repeatedupsidedown.appenditem(list.nitems.nextindex);
list.human_uprightitems_repeatedupsidedown.appenditem(list.nitems.nextindex);
list.human_uprightitems_repeatedupsidedown.appenditem(list.nitems.nextindex);
list.human_uprightitems_repeatedupsidedown.appenditem(list.nitems.nextindex);
list.human_uprightitems_repeatedupsidedown.appenditem(list.nitems.nextindex);
list.human_uprightitems_repeatedupsidedown.appenditem(list.nitems.nextindex);
list.human_uprightitems_repeatedupsidedown.appenditem(list.nitems.nextindex);
list.human_uprightitems_repeatedupsidedown.appenditem(list.nitems.nextindex);
list.human_uprightitems_repeatedupsidedown.appenditem(list.nitems.nextindex);

list.android_uprightitems_repeatedupright.appenditem(list.nitems.nextindex);
list.android_uprightitems_repeatedupright.appenditem(list.nitems.nextindex);
list.android_uprightitems_repeatedupright.appenditem(list.nitems.nextindex);
list.android_uprightitems_repeatedupright.appenditem(list.nitems.nextindex);
list.android_uprightitems_repeatedupright.appenditem(list.nitems.nextindex);
list.android_uprightitems_repeatedupright.appenditem(list.nitems.nextindex);
list.android_uprightitems_repeatedupright.appenditem(list.nitems.nextindex);
list.android_uprightitems_repeatedupright.appenditem(list.nitems.nextindex);
list.android_uprightitems_repeatedupright.appenditem(list.nitems.nextindex);
list.android_uprightitems_repeatedupsidedown.appenditem(list.nitems.nextindex);
list.android_uprightitems_repeatedupsidedown.appenditem(list.nitems.nextindex);
list.android_uprightitems_repeatedupsidedown.appenditem(list.nitems.nextindex);
list.android_uprightitems_repeatedupsidedown.appenditem(list.nitems.nextindex);
list.android_uprightitems_repeatedupsidedown.appenditem(list.nitems.nextindex);
list.android_uprightitems_repeatedupsidedown.appenditem(list.nitems.nextindex);
list.android_uprightitems_repeatedupsidedown.appenditem(list.nitems.nextindex);
list.android_uprightitems_repeatedupsidedown.appenditem(list.nitems.nextindex);
list.android_uprightitems_repeatedupsidedown.appenditem(list.nitems.nextindex);

list.upright_test_items.appenditem(list.nitems.nextindex);
list.upright_test_items.appenditem(list.nitems.nextindex);
list.upright_test_items.appenditem(list.nitems.nextindex);
list.upright_test_items.appenditem(list.nitems.nextindex);
list.upright_test_items.appenditem(list.nitems.nextindex);
list.upright_test_items.appenditem(list.nitems.nextindex);
list.upright_test_items.appenditem(list.nitems.nextindex);
list.upright_test_items.appenditem(list.nitems.nextindex);
list.upright_test_items.appenditem(list.nitems.nextindex);
list.upright_test_items.appenditem(list.nitems.nextindex);
list.upright_test_items.appenditem(list.nitems.nextindex);
list.upright_test_items.appenditem(list.nitems.nextindex);
list.upright_test_items.appenditem(list.nitems.nextindex);
list.upright_test_items.appenditem(list.nitems.nextindex);
list.upright_test_items.appenditem(list.nitems.nextindex);
list.upright_test_items.appenditem(list.nitems.nextindex);
list.upright_test_items.appenditem(list.nitems.nextindex);
list.upright_test_items.appenditem(list.nitems.nextindex);


list.upside_down_test_items.appenditem(list.nitems.nextindex);
list.upside_down_test_items.appenditem(list.nitems.nextindex);
list.upside_down_test_items.appenditem(list.nitems.nextindex);
list.upside_down_test_items.appenditem(list.nitems.nextindex);
list.upside_down_test_items.appenditem(list.nitems.nextindex);
list.upside_down_test_items.appenditem(list.nitems.nextindex);
list.upside_down_test_items.appenditem(list.nitems.nextindex);
list.upside_down_test_items.appenditem(list.nitems.nextindex);
list.upside_down_test_items.appenditem(list.nitems.nextindex);
list.upside_down_test_items.appenditem(list.nitems.nextindex);
list.upside_down_test_items.appenditem(list.nitems.nextindex);
list.upside_down_test_items.appenditem(list.nitems.nextindex);
list.upside_down_test_items.appenditem(list.nitems.nextindex);
list.upside_down_test_items.appenditem(list.nitems.nextindex);
list.upside_down_test_items.appenditem(list.nitems.nextindex);
list.upside_down_test_items.appenditem(list.nitems.nextindex);
list.upside_down_test_items.appenditem(list.nitems.nextindex);
list.upside_down_test_items.appenditem(list.nitems.nextindex);



]

/ blocks = [
1 = intro_Attention_Check;
2 = intro_1;
3 = intro_2;
4 = intro_3;
5 = intro_4;
6 = intro_6;
7 = intro_7;
8 = intro_8;
9 = intro_5;
10 = human_android_upright;
11 = testingphase;
12 = human_android_test]

</expt>

I've attached a version of your script that does that -- please give this a shot at your earliest convenience and let me know if it makes any difference as far as the transfer of the subject ID is concerned.

Attachments
pareidolia_inversion_task.iqx (491 views, 22.00 KB)
amomen425
amomen425
Esteemed Member (1.7K reputation)Esteemed Member (1.7K reputation)Esteemed Member (1.7K reputation)Esteemed Member (1.7K reputation)Esteemed Member (1.7K reputation)Esteemed Member (1.7K reputation)Esteemed Member (1.7K reputation)Esteemed Member (1.7K reputation)Esteemed Member (1.7K reputation)
Group: Forum Members
Posts: 21, Visits: 99
Dave - Friday, December 14, 2018
amomen425 - Friday, December 14, 2018
I always used to be able to get the participant ID using query parameters, but, now as you can see (image of csv data sheet attached), inquisit spits out these weird characters. I don't think I am doing anything wrong since every so often it spits the correct participant ID (i.e., '240'). What to do?

https://www.millisecond.com/forums/Uploads/Images/7c52e4f8-c398-4472-8890-03da.png

It's not possible to say where / what the issue may be without seeing the actual set up of the web script. Would it be possible to share the link to the experiment's start page here, please?

Of course.
Here is the link: https://mili2nd.co/2clb
Dave
Dave
Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)
Group: Administrators
Posts: 13K, Visits: 104K
amomen425 - Friday, December 14, 2018
I always used to be able to get the participant ID using query parameters, but, now as you can see (image of csv data sheet attached), inquisit spits out these weird characters. I don't think I am doing anything wrong since every so often it spits the correct participant ID (i.e., '240'). What to do?

https://www.millisecond.com/forums/Uploads/Images/7c52e4f8-c398-4472-8890-03da.png

It's not possible to say where / what the issue may be without seeing the actual set up of the web script. Would it be possible to share the link to the experiment's start page here, please?

amomen425
amomen425
Esteemed Member (1.7K reputation)Esteemed Member (1.7K reputation)Esteemed Member (1.7K reputation)Esteemed Member (1.7K reputation)Esteemed Member (1.7K reputation)Esteemed Member (1.7K reputation)Esteemed Member (1.7K reputation)Esteemed Member (1.7K reputation)Esteemed Member (1.7K reputation)
Group: Forum Members
Posts: 21, Visits: 99
I always used to be able to get the participant ID using query parameters, but, now as you can see (image of csv data sheet attached), inquisit spits out these weird characters. I don't think I am doing anything wrong since every so often it spits the correct participant ID (i.e., '240'). What to do?

https://www.millisecond.com/forums/Uploads/Images/7c52e4f8-c398-4472-8890-03da.png
GO

Merge Selected

Merge into selected topic...



Merge into merge target...



Merge into a specific topic ID...




Reading This Topic

Explore
Messages
Mentions
Search