Millisecond Forums

direct one condition to an external link?

https://forums.millisecond.com/Topic28500.aspx

By xizhouxie - 3/11/2020

We are currently trying to develop a study with the following two conditions. The first condition will be done once they complete the Inquisit survey. In the second condition, we need participants to be redirected to an external webpage once they finish the Inquisit survey. Is there any way we can do that? I tried imbedding the website within inquisit, but that was extremely clunky and there was no way to click anything.
By Dave - 3/11/2020

xizhouxie - 3/11/2020
We are currently trying to develop a study with the following two conditions. The first condition will be done once they complete the Inquisit survey. In the second condition, we need participants to be redirected to an external webpage once they finish the Inquisit survey. Is there any way we can do that? I tried imbedding the website within inquisit, but that was extremely clunky and there was no way to click anything.

Yes, you can do that by setting the defaults.finishpage property to the external URL in the one condition, but not the other. I.e. if you have two <expt>s for the respective conditions, do

// condition 1: No redirection
<expt>
/ subjects = (1 of 2)
/ groupassignment = groupnumber
...
</expt>

// condition 2: Redirect to external URL
<expt>
/ onexptend = [
    defaults.finishpage = concat("https://www.example.com/?subjectid=", script.subjectid);
]
/ subjects = (2 of 2)
/ groupassignment = groupnumber
...
</expt>


If you are running things via <batch>, the defaults.finishpage ought to be set at the end of the batch instead:

// condition 1: No redirection
<batch>
/ subjects = (1 of 2)
/ groupassignment = groupnumber
...
/ file = "condition1.iqx"
</batch>

// condition 2: Redirect to external URL
<batch>
/ subjects = (2 of 2)
/ groupassignment = groupnumber
...
/ file = "condition2.iqx"
/ onscriptend = [if (batch.2.currentscript == "condition2.iqx") defaults.finishpage = concat("https://www.example.com/?subjectid=", script.subjectd);]
</batch>
By xizhouxie - 3/11/2020

Dave - 3/11/2020
xizhouxie - 3/11/2020
We are currently trying to develop a study with the following two conditions. The first condition will be done once they complete the Inquisit survey. In the second condition, we need participants to be redirected to an external webpage once they finish the Inquisit survey. Is there any way we can do that? I tried imbedding the website within inquisit, but that was extremely clunky and there was no way to click anything.

Yes, you can do that by setting the defaults.finishpage property to the external URL in the one condition, but not the other. I.e. if you have two <expt>s for the respective conditions, do

// condition 1: No redirection
<expt>
/ subjects = (1 of 2)
/ groupassignment = groupnumber
...
</expt>

// condition 2: Redirect to external URL
<expt>
/ onexptend = [
    defaults.finishpage = concat("https://www.example.com/?subjectid=", script.subjectid);
]
/ subjects = (2 of 2)
/ groupassignment = groupnumber
...
</expt>


If you are running things via <batch>, the defaults.finishpage ought to be set at the end of the batch instead:

// condition 1: No redirection
<batch>
/ subjects = (1 of 2)
/ groupassignment = groupnumber
...
/ file = "condition1.iqx"
</batch>

// condition 2: Redirect to external URL
<batch>
/ subjects = (2 of 2)
/ groupassignment = groupnumber
...
/ file = "condition2.iqx"
/ onscriptend = [if (batch.2.currentscript == "condition2.iqx") defaults.finishpage = concat("https://www.example.com/?subjectid=", script.subjectd);]
</batch>

Thanks Dave. I will try that and report back. Is the subjectid in the link necessary? They are going to another page where they need to sign in, so we won't need their subjectid to link the data.
By Dave - 3/11/2020

xizhouxie - 3/11/2020
Dave - 3/11/2020
xizhouxie - 3/11/2020
We are currently trying to develop a study with the following two conditions. The first condition will be done once they complete the Inquisit survey. In the second condition, we need participants to be redirected to an external webpage once they finish the Inquisit survey. Is there any way we can do that? I tried imbedding the website within inquisit, but that was extremely clunky and there was no way to click anything.

Yes, you can do that by setting the defaults.finishpage property to the external URL in the one condition, but not the other. I.e. if you have two <expt>s for the respective conditions, do

// condition 1: No redirection
<expt>
/ subjects = (1 of 2)
/ groupassignment = groupnumber
...
</expt>

// condition 2: Redirect to external URL
<expt>
/ onexptend = [
    defaults.finishpage = concat("https://www.example.com/?subjectid=", script.subjectid);
]
/ subjects = (2 of 2)
/ groupassignment = groupnumber
...
</expt>


If you are running things via <batch>, the defaults.finishpage ought to be set at the end of the batch instead:

// condition 1: No redirection
<batch>
/ subjects = (1 of 2)
/ groupassignment = groupnumber
...
/ file = "condition1.iqx"
</batch>

// condition 2: Redirect to external URL
<batch>
/ subjects = (2 of 2)
/ groupassignment = groupnumber
...
/ file = "condition2.iqx"
/ onscriptend = [if (batch.2.currentscript == "condition2.iqx") defaults.finishpage = concat("https://www.example.com/?subjectid=", script.subjectd);]
</batch>

Thanks Dave. I will try that and report back. Is the subjectid in the link necessary? They are going to another page where they need to sign in, so we won't need their subjectid to link the data.

Then it's not necessary.
By abalbert - 2/8/2021

Hi Dave/Administrators,
I am new to Inquisit Web and trying to do something similar to the above, but am having difficulty adjusting the script to my needs.
I have an experiment with two groups. They start off at different Qualtrics surveys, and then are sent to Inquisit from there, with participant ID and group ID (either group 1 or group 2) carried forward in the URL. Each group will complete the corsi block task, but only group 1 will complete the digit symbol task. When each group finishes their Inquisit tasks, I want them to be redirected again to two different Qualtrics URLs based on their original group membership (group 1 goes to one URL, group 2 goes to another). I've got all the other parts working, but cannot seem to make this redirection to different URLs after completion of the Inquisit tasks work, after several attempts at adjusting the code in different ways. Would you be able to help me with this?
Here is my code right now (with fake URLs). Currently it is giving me an error message that says "'script.groupid, 2' The expression contains an unknown property"

// session 1 groups 1 & 2
<batch>
/ file = "corsiblocktappingtask.iqx"
/ file = "group1_vs_group2.iqx"
/ sessions = (1 of 1)
/ onscriptend = [if(script.groupid, 2 == 1) defaults.finishpage = concat("https://syracuseuniversity.qualtrics.com/group1part2"); ]
/ onscriptend = [if(script.groupid, 2 == 2) defaults.finishpage = concat("https://syracuseuniversity.qualtrics.com/group2part2"); ]
</batch>

See contents of the file "group1_vs_group2.iqx" also below. Maybe there is a way to add the different finish page URL to this script, as it's already describing a modification based on group ID?

<include>
/ precondition = [
    mod(script.groupid, 2) == 1;
]
/ file = "digitsymbolsubstitutiontask_test1.iqx"
</include>


By Dave - 2/8/2021

abalbert - 2/8/2021
Hi Dave/Administrators,
I am new to Inquisit Web and trying to do something similar to the above, but am having difficulty adjusting the script to my needs.
I have an experiment with two groups. They start off at different Qualtrics surveys, and then are sent to Inquisit from there, with participant ID and group ID (either group 1 or group 2) carried forward in the URL. Each group will complete the corsi block task, but only group 1 will complete the digit symbol task. When each group finishes their Inquisit tasks, I want them to be redirected again to two different Qualtrics URLs based on their original group membership (group 1 goes to one URL, group 2 goes to another). I've got all the other parts working, but cannot seem to make this redirection to different URLs after completion of the Inquisit tasks work, after several attempts at adjusting the code in different ways. Would you be able to help me with this?
Here is my code right now (with fake URLs). Currently it is giving me an error message that says "'script.groupid, 2' The expression contains an unknown property"

// session 1 groups 1 & 2
<batch>
/ file = "corsiblocktappingtask.iqx"
/ file = "group1_vs_group2.iqx"
/ sessions = (1 of 1)
/ onscriptend = [if(script.groupid, 2 == 1) defaults.finishpage = concat("https://syracuseuniversity.qualtrics.com/group1part2"); ]
/ onscriptend = [if(script.groupid, 2 == 2) defaults.finishpage = concat("https://syracuseuniversity.qualtrics.com/group2part2"); ]
</batch>

See contents of the file "group1_vs_group2.iqx" also below. Maybe there is a way to add the different finish page URL to this script, as it's already describing a modification based on group ID?

<include>
/ precondition = [
    mod(script.groupid, 2) == 1;
]
/ file = "digitsymbolsubstitutiontask_test1.iqx"
</include>



/ onscriptend = [if(script.groupid, 2 == 1) defaults.finishpage = concat("https://syracuseuniversity.qualtrics.com/group1part2"); ]
/ onscriptend = [if(script.groupid, 2 == 2) defaults.finishpage = concat("https://syracuseuniversity.qualtrics.com/group2part2"); ]

is wrong, you want something like

/ onscriptend = [if(mod(script.groupid, 2) == 1) defaults.finishpage = concat("https://syracuseuniversity.qualtrics.com/group1part2"); ]
/ onscriptend = [if(mod(script.groupid, 2) == 0) defaults.finishpage = concat("https://syracuseuniversity.qualtrics.com/group2part2"); ]
By abalbert - 2/8/2021

Dave - 2/8/2021
abalbert - 2/8/2021
Hi Dave/Administrators,
I am new to Inquisit Web and trying to do something similar to the above, but am having difficulty adjusting the script to my needs.
I have an experiment with two groups. They start off at different Qualtrics surveys, and then are sent to Inquisit from there, with participant ID and group ID (either group 1 or group 2) carried forward in the URL. Each group will complete the corsi block task, but only group 1 will complete the digit symbol task. When each group finishes their Inquisit tasks, I want them to be redirected again to two different Qualtrics URLs based on their original group membership (group 1 goes to one URL, group 2 goes to another). I've got all the other parts working, but cannot seem to make this redirection to different URLs after completion of the Inquisit tasks work, after several attempts at adjusting the code in different ways. Would you be able to help me with this?
Here is my code right now (with fake URLs). Currently it is giving me an error message that says "'script.groupid, 2' The expression contains an unknown property"

// session 1 groups 1 & 2
<batch>
/ file = "corsiblocktappingtask.iqx"
/ file = "group1_vs_group2.iqx"
/ sessions = (1 of 1)
/ onscriptend = [if(script.groupid, 2 == 1) defaults.finishpage = concat("https://syracuseuniversity.qualtrics.com/group1part2"); ]
/ onscriptend = [if(script.groupid, 2 == 2) defaults.finishpage = concat("https://syracuseuniversity.qualtrics.com/group2part2"); ]
</batch>

See contents of the file "group1_vs_group2.iqx" also below. Maybe there is a way to add the different finish page URL to this script, as it's already describing a modification based on group ID?

<include>
/ precondition = [
    mod(script.groupid, 2) == 1;
]
/ file = "digitsymbolsubstitutiontask_test1.iqx"
</include>



/ onscriptend = [if(script.groupid, 2 == 1) defaults.finishpage = concat("https://syracuseuniversity.qualtrics.com/group1part2"); ]
/ onscriptend = [if(script.groupid, 2 == 2) defaults.finishpage = concat("https://syracuseuniversity.qualtrics.com/group2part2"); ]

is wrong, you want something like

/ onscriptend = [if(mod(script.groupid, 2) == 1) defaults.finishpage = concat("https://syracuseuniversity.qualtrics.com/group1part2"); ]
/ onscriptend = [if(mod(script.groupid, 2) == 0) defaults.finishpage = concat("https://syracuseuniversity.qualtrics.com/group2part2"); ]

Thank you so much for your quick reply! I made these adjustments, and now the experiment is running without the error, but still not redirecting to the correct URL for group 1. Instead, both groups are being redirected to the group 2 finish page (which is the one listed as the finish page in my inquisit web experiment settings). Any other help you can provide with redirecting the groups correctly would be greatly appreciated!
By Dave - 2/8/2021

abalbert - 2/8/2021
Dave - 2/8/2021
abalbert - 2/8/2021
Hi Dave/Administrators,
I am new to Inquisit Web and trying to do something similar to the above, but am having difficulty adjusting the script to my needs.
I have an experiment with two groups. They start off at different Qualtrics surveys, and then are sent to Inquisit from there, with participant ID and group ID (either group 1 or group 2) carried forward in the URL. Each group will complete the corsi block task, but only group 1 will complete the digit symbol task. When each group finishes their Inquisit tasks, I want them to be redirected again to two different Qualtrics URLs based on their original group membership (group 1 goes to one URL, group 2 goes to another). I've got all the other parts working, but cannot seem to make this redirection to different URLs after completion of the Inquisit tasks work, after several attempts at adjusting the code in different ways. Would you be able to help me with this?
Here is my code right now (with fake URLs). Currently it is giving me an error message that says "'script.groupid, 2' The expression contains an unknown property"

// session 1 groups 1 & 2
<batch>
/ file = "corsiblocktappingtask.iqx"
/ file = "group1_vs_group2.iqx"
/ sessions = (1 of 1)
/ onscriptend = [if(script.groupid, 2 == 1) defaults.finishpage = concat("https://syracuseuniversity.qualtrics.com/group1part2"); ]
/ onscriptend = [if(script.groupid, 2 == 2) defaults.finishpage = concat("https://syracuseuniversity.qualtrics.com/group2part2"); ]
</batch>

See contents of the file "group1_vs_group2.iqx" also below. Maybe there is a way to add the different finish page URL to this script, as it's already describing a modification based on group ID?

<include>
/ precondition = [
    mod(script.groupid, 2) == 1;
]
/ file = "digitsymbolsubstitutiontask_test1.iqx"
</include>



/ onscriptend = [if(script.groupid, 2 == 1) defaults.finishpage = concat("https://syracuseuniversity.qualtrics.com/group1part2"); ]
/ onscriptend = [if(script.groupid, 2 == 2) defaults.finishpage = concat("https://syracuseuniversity.qualtrics.com/group2part2"); ]

is wrong, you want something like

/ onscriptend = [if(mod(script.groupid, 2) == 1) defaults.finishpage = concat("https://syracuseuniversity.qualtrics.com/group1part2"); ]
/ onscriptend = [if(mod(script.groupid, 2) == 0) defaults.finishpage = concat("https://syracuseuniversity.qualtrics.com/group2part2"); ]

Thank you so much for your quick reply! I made these adjustments, and now the experiment is running without the error, but still not redirecting to the correct URL for group 1. Instead, both groups are being redirected to the group 2 finish page (which is the one listed as the finish page in my inquisit web experiment settings). Any other help you can provide with redirecting the groups correctly would be greatly appreciated!

For anything further you will need to provide the link to the online study.
By abalbert - 2/8/2021

Dave - 2/8/2021
abalbert - 2/8/2021
Dave - 2/8/2021
abalbert - 2/8/2021
Hi Dave/Administrators,
I am new to Inquisit Web and trying to do something similar to the above, but am having difficulty adjusting the script to my needs.
I have an experiment with two groups. They start off at different Qualtrics surveys, and then are sent to Inquisit from there, with participant ID and group ID (either group 1 or group 2) carried forward in the URL. Each group will complete the corsi block task, but only group 1 will complete the digit symbol task. When each group finishes their Inquisit tasks, I want them to be redirected again to two different Qualtrics URLs based on their original group membership (group 1 goes to one URL, group 2 goes to another). I've got all the other parts working, but cannot seem to make this redirection to different URLs after completion of the Inquisit tasks work, after several attempts at adjusting the code in different ways. Would you be able to help me with this?
Here is my code right now (with fake URLs). Currently it is giving me an error message that says "'script.groupid, 2' The expression contains an unknown property"

// session 1 groups 1 & 2
<batch>
/ file = "corsiblocktappingtask.iqx"
/ file = "group1_vs_group2.iqx"
/ sessions = (1 of 1)
/ onscriptend = [if(script.groupid, 2 == 1) defaults.finishpage = concat("https://syracuseuniversity.qualtrics.com/group1part2"); ]
/ onscriptend = [if(script.groupid, 2 == 2) defaults.finishpage = concat("https://syracuseuniversity.qualtrics.com/group2part2"); ]
</batch>

See contents of the file "group1_vs_group2.iqx" also below. Maybe there is a way to add the different finish page URL to this script, as it's already describing a modification based on group ID?

<include>
/ precondition = [
    mod(script.groupid, 2) == 1;
]
/ file = "digitsymbolsubstitutiontask_test1.iqx"
</include>



/ onscriptend = [if(script.groupid, 2 == 1) defaults.finishpage = concat("https://syracuseuniversity.qualtrics.com/group1part2"); ]
/ onscriptend = [if(script.groupid, 2 == 2) defaults.finishpage = concat("https://syracuseuniversity.qualtrics.com/group2part2"); ]

is wrong, you want something like

/ onscriptend = [if(mod(script.groupid, 2) == 1) defaults.finishpage = concat("https://syracuseuniversity.qualtrics.com/group1part2"); ]
/ onscriptend = [if(mod(script.groupid, 2) == 0) defaults.finishpage = concat("https://syracuseuniversity.qualtrics.com/group2part2"); ]

Thank you so much for your quick reply! I made these adjustments, and now the experiment is running without the error, but still not redirecting to the correct URL for group 1. Instead, both groups are being redirected to the group 2 finish page (which is the one listed as the finish page in my inquisit web experiment settings). Any other help you can provide with redirecting the groups correctly would be greatly appreciated!

For anything further you will need to provide the link to the online study.

Hi Dave, sorry for my ignorance, but what link should I provide to you? the launch page? or is there another link that would allow you access to the actual scripts? My web experiment script name is "GREpredictors" if that helps. Thanks again!
By Dave - 2/8/2021

abalbert - 2/8/2021
Dave - 2/8/2021
abalbert - 2/8/2021
Dave - 2/8/2021
abalbert - 2/8/2021
Hi Dave/Administrators,
I am new to Inquisit Web and trying to do something similar to the above, but am having difficulty adjusting the script to my needs.
I have an experiment with two groups. They start off at different Qualtrics surveys, and then are sent to Inquisit from there, with participant ID and group ID (either group 1 or group 2) carried forward in the URL. Each group will complete the corsi block task, but only group 1 will complete the digit symbol task. When each group finishes their Inquisit tasks, I want them to be redirected again to two different Qualtrics URLs based on their original group membership (group 1 goes to one URL, group 2 goes to another). I've got all the other parts working, but cannot seem to make this redirection to different URLs after completion of the Inquisit tasks work, after several attempts at adjusting the code in different ways. Would you be able to help me with this?
Here is my code right now (with fake URLs). Currently it is giving me an error message that says "'script.groupid, 2' The expression contains an unknown property"

// session 1 groups 1 & 2
<batch>
/ file = "corsiblocktappingtask.iqx"
/ file = "group1_vs_group2.iqx"
/ sessions = (1 of 1)
/ onscriptend = [if(script.groupid, 2 == 1) defaults.finishpage = concat("https://syracuseuniversity.qualtrics.com/group1part2"); ]
/ onscriptend = [if(script.groupid, 2 == 2) defaults.finishpage = concat("https://syracuseuniversity.qualtrics.com/group2part2"); ]
</batch>

See contents of the file "group1_vs_group2.iqx" also below. Maybe there is a way to add the different finish page URL to this script, as it's already describing a modification based on group ID?

<include>
/ precondition = [
    mod(script.groupid, 2) == 1;
]
/ file = "digitsymbolsubstitutiontask_test1.iqx"
</include>



/ onscriptend = [if(script.groupid, 2 == 1) defaults.finishpage = concat("https://syracuseuniversity.qualtrics.com/group1part2"); ]
/ onscriptend = [if(script.groupid, 2 == 2) defaults.finishpage = concat("https://syracuseuniversity.qualtrics.com/group2part2"); ]

is wrong, you want something like

/ onscriptend = [if(mod(script.groupid, 2) == 1) defaults.finishpage = concat("https://syracuseuniversity.qualtrics.com/group1part2"); ]
/ onscriptend = [if(mod(script.groupid, 2) == 0) defaults.finishpage = concat("https://syracuseuniversity.qualtrics.com/group2part2"); ]

Thank you so much for your quick reply! I made these adjustments, and now the experiment is running without the error, but still not redirecting to the correct URL for group 1. Instead, both groups are being redirected to the group 2 finish page (which is the one listed as the finish page in my inquisit web experiment settings). Any other help you can provide with redirecting the groups correctly would be greatly appreciated!

For anything further you will need to provide the link to the online study.

Hi Dave, sorry for my ignorance, but what link should I provide to you? the launch page? or is there another link that would allow you access to the actual scripts? My web experiment script name is "GREpredictors" if that helps. Thanks again!

> the launch page?

Yes.
By abalbert - 2/8/2021

Dave - 2/8/2021
abalbert - 2/8/2021
Dave - 2/8/2021
abalbert - 2/8/2021
Dave - 2/8/2021
abalbert - 2/8/2021
Hi Dave/Administrators,
I am new to Inquisit Web and trying to do something similar to the above, but am having difficulty adjusting the script to my needs.
I have an experiment with two groups. They start off at different Qualtrics surveys, and then are sent to Inquisit from there, with participant ID and group ID (either group 1 or group 2) carried forward in the URL. Each group will complete the corsi block task, but only group 1 will complete the digit symbol task. When each group finishes their Inquisit tasks, I want them to be redirected again to two different Qualtrics URLs based on their original group membership (group 1 goes to one URL, group 2 goes to another). I've got all the other parts working, but cannot seem to make this redirection to different URLs after completion of the Inquisit tasks work, after several attempts at adjusting the code in different ways. Would you be able to help me with this?
Here is my code right now (with fake URLs). Currently it is giving me an error message that says "'script.groupid, 2' The expression contains an unknown property"

// session 1 groups 1 & 2
<batch>
/ file = "corsiblocktappingtask.iqx"
/ file = "group1_vs_group2.iqx"
/ sessions = (1 of 1)
/ onscriptend = [if(script.groupid, 2 == 1) defaults.finishpage = concat("https://syracuseuniversity.qualtrics.com/group1part2"); ]
/ onscriptend = [if(script.groupid, 2 == 2) defaults.finishpage = concat("https://syracuseuniversity.qualtrics.com/group2part2"); ]
</batch>

See contents of the file "group1_vs_group2.iqx" also below. Maybe there is a way to add the different finish page URL to this script, as it's already describing a modification based on group ID?

<include>
/ precondition = [
    mod(script.groupid, 2) == 1;
]
/ file = "digitsymbolsubstitutiontask_test1.iqx"
</include>



/ onscriptend = [if(script.groupid, 2 == 1) defaults.finishpage = concat("https://syracuseuniversity.qualtrics.com/group1part2"); ]
/ onscriptend = [if(script.groupid, 2 == 2) defaults.finishpage = concat("https://syracuseuniversity.qualtrics.com/group2part2"); ]

is wrong, you want something like

/ onscriptend = [if(mod(script.groupid, 2) == 1) defaults.finishpage = concat("https://syracuseuniversity.qualtrics.com/group1part2"); ]
/ onscriptend = [if(mod(script.groupid, 2) == 0) defaults.finishpage = concat("https://syracuseuniversity.qualtrics.com/group2part2"); ]

Thank you so much for your quick reply! I made these adjustments, and now the experiment is running without the error, but still not redirecting to the correct URL for group 1. Instead, both groups are being redirected to the group 2 finish page (which is the one listed as the finish page in my inquisit web experiment settings). Any other help you can provide with redirecting the groups correctly would be greatly appreciated!

For anything further you will need to provide the link to the online study.

Hi Dave, sorry for my ignorance, but what link should I provide to you? the launch page? or is there another link that would allow you access to the actual scripts? My web experiment script name is "GREpredictors" if that helps. Thanks again!

> the launch page?

Yes.

Okay, here is the launch page: https://mili2nd.co/wqxb
By Dave - 2/8/2021

abalbert - 2/8/2021
Dave - 2/8/2021
abalbert - 2/8/2021
Dave - 2/8/2021
abalbert - 2/8/2021
Dave - 2/8/2021
abalbert - 2/8/2021
Hi Dave/Administrators,
I am new to Inquisit Web and trying to do something similar to the above, but am having difficulty adjusting the script to my needs.
I have an experiment with two groups. They start off at different Qualtrics surveys, and then are sent to Inquisit from there, with participant ID and group ID (either group 1 or group 2) carried forward in the URL. Each group will complete the corsi block task, but only group 1 will complete the digit symbol task. When each group finishes their Inquisit tasks, I want them to be redirected again to two different Qualtrics URLs based on their original group membership (group 1 goes to one URL, group 2 goes to another). I've got all the other parts working, but cannot seem to make this redirection to different URLs after completion of the Inquisit tasks work, after several attempts at adjusting the code in different ways. Would you be able to help me with this?
Here is my code right now (with fake URLs). Currently it is giving me an error message that says "'script.groupid, 2' The expression contains an unknown property"

// session 1 groups 1 & 2
<batch>
/ file = "corsiblocktappingtask.iqx"
/ file = "group1_vs_group2.iqx"
/ sessions = (1 of 1)
/ onscriptend = [if(script.groupid, 2 == 1) defaults.finishpage = concat("https://syracuseuniversity.qualtrics.com/group1part2"); ]
/ onscriptend = [if(script.groupid, 2 == 2) defaults.finishpage = concat("https://syracuseuniversity.qualtrics.com/group2part2"); ]
</batch>

See contents of the file "group1_vs_group2.iqx" also below. Maybe there is a way to add the different finish page URL to this script, as it's already describing a modification based on group ID?

<include>
/ precondition = [
    mod(script.groupid, 2) == 1;
]
/ file = "digitsymbolsubstitutiontask_test1.iqx"
</include>



/ onscriptend = [if(script.groupid, 2 == 1) defaults.finishpage = concat("https://syracuseuniversity.qualtrics.com/group1part2"); ]
/ onscriptend = [if(script.groupid, 2 == 2) defaults.finishpage = concat("https://syracuseuniversity.qualtrics.com/group2part2"); ]

is wrong, you want something like

/ onscriptend = [if(mod(script.groupid, 2) == 1) defaults.finishpage = concat("https://syracuseuniversity.qualtrics.com/group1part2"); ]
/ onscriptend = [if(mod(script.groupid, 2) == 0) defaults.finishpage = concat("https://syracuseuniversity.qualtrics.com/group2part2"); ]

Thank you so much for your quick reply! I made these adjustments, and now the experiment is running without the error, but still not redirecting to the correct URL for group 1. Instead, both groups are being redirected to the group 2 finish page (which is the one listed as the finish page in my inquisit web experiment settings). Any other help you can provide with redirecting the groups correctly would be greatly appreciated!

For anything further you will need to provide the link to the online study.

Hi Dave, sorry for my ignorance, but what link should I provide to you? the launch page? or is there another link that would allow you access to the actual scripts? My web experiment script name is "GREpredictors" if that helps. Thanks again!

> the launch page?

Yes.

Okay, here is the launch page: https://mili2nd.co/wqxb

Thank you for the link. One issue is the URL specified in the online settings:

Under Inquisit 6 Web, that will always take precendence over anything set by the script(s). That is: If one plans to set the finish URL via some logic in the script, one should always leave the online settings at their default / not specify any external URL there. (This used to be different under Inquisit 5.)

However, there appears to be a bug in the current release 6.3.4 / 6.3.5 that prevents defaults.finishpage from being set properly regardless. I have logged that bug and we'll get that fixed in for either 6.4.0 due out towards the end of the week or 6.4.1 at the latest.
By abalbert - 2/9/2021

Dave - 2/8/2021
abalbert - 2/8/2021
Dave - 2/8/2021
abalbert - 2/8/2021
Dave - 2/8/2021
abalbert - 2/8/2021
Dave - 2/8/2021
abalbert - 2/8/2021
Hi Dave/Administrators,
I am new to Inquisit Web and trying to do something similar to the above, but am having difficulty adjusting the script to my needs.
I have an experiment with two groups. They start off at different Qualtrics surveys, and then are sent to Inquisit from there, with participant ID and group ID (either group 1 or group 2) carried forward in the URL. Each group will complete the corsi block task, but only group 1 will complete the digit symbol task. When each group finishes their Inquisit tasks, I want them to be redirected again to two different Qualtrics URLs based on their original group membership (group 1 goes to one URL, group 2 goes to another). I've got all the other parts working, but cannot seem to make this redirection to different URLs after completion of the Inquisit tasks work, after several attempts at adjusting the code in different ways. Would you be able to help me with this?
Here is my code right now (with fake URLs). Currently it is giving me an error message that says "'script.groupid, 2' The expression contains an unknown property"

// session 1 groups 1 & 2
<batch>
/ file = "corsiblocktappingtask.iqx"
/ file = "group1_vs_group2.iqx"
/ sessions = (1 of 1)
/ onscriptend = [if(script.groupid, 2 == 1) defaults.finishpage = concat("https://syracuseuniversity.qualtrics.com/group1part2"); ]
/ onscriptend = [if(script.groupid, 2 == 2) defaults.finishpage = concat("https://syracuseuniversity.qualtrics.com/group2part2"); ]
</batch>

See contents of the file "group1_vs_group2.iqx" also below. Maybe there is a way to add the different finish page URL to this script, as it's already describing a modification based on group ID?

<include>
/ precondition = [
    mod(script.groupid, 2) == 1;
]
/ file = "digitsymbolsubstitutiontask_test1.iqx"
</include>



/ onscriptend = [if(script.groupid, 2 == 1) defaults.finishpage = concat("https://syracuseuniversity.qualtrics.com/group1part2"); ]
/ onscriptend = [if(script.groupid, 2 == 2) defaults.finishpage = concat("https://syracuseuniversity.qualtrics.com/group2part2"); ]

is wrong, you want something like

/ onscriptend = [if(mod(script.groupid, 2) == 1) defaults.finishpage = concat("https://syracuseuniversity.qualtrics.com/group1part2"); ]
/ onscriptend = [if(mod(script.groupid, 2) == 0) defaults.finishpage = concat("https://syracuseuniversity.qualtrics.com/group2part2"); ]

Thank you so much for your quick reply! I made these adjustments, and now the experiment is running without the error, but still not redirecting to the correct URL for group 1. Instead, both groups are being redirected to the group 2 finish page (which is the one listed as the finish page in my inquisit web experiment settings). Any other help you can provide with redirecting the groups correctly would be greatly appreciated!

For anything further you will need to provide the link to the online study.

Hi Dave, sorry for my ignorance, but what link should I provide to you? the launch page? or is there another link that would allow you access to the actual scripts? My web experiment script name is "GREpredictors" if that helps. Thanks again!

> the launch page?

Yes.

Okay, here is the launch page: https://mili2nd.co/wqxb

Thank you for the link. One issue is the URL specified in the online settings:

Under Inquisit 6 Web, that will always take precendence over anything set by the script(s). That is: If one plans to set the finish URL via some logic in the script, one should always leave the online settings at their default / not specify any external URL there. (This used to be different under Inquisit 5.)

However, there appears to be a bug in the current release 6.3.4 / 6.3.5 that prevents defaults.finishpage from being set properly regardless. I have logged that bug and we'll get that fixed in for either 6.4.0 due out towards the end of the week or 6.4.1 at the latest.

Got it! Thank you so much for your help with this! I appreciate it!
By abalbert - 2/22/2021

abalbert - 2/9/2021
Dave - 2/8/2021
abalbert - 2/8/2021
Dave - 2/8/2021
abalbert - 2/8/2021
Dave - 2/8/2021
abalbert - 2/8/2021
Dave - 2/8/2021
abalbert - 2/8/2021
Hi Dave/Administrators,
I am new to Inquisit Web and trying to do something similar to the above, but am having difficulty adjusting the script to my needs.
I have an experiment with two groups. They start off at different Qualtrics surveys, and then are sent to Inquisit from there, with participant ID and group ID (either group 1 or group 2) carried forward in the URL. Each group will complete the corsi block task, but only group 1 will complete the digit symbol task. When each group finishes their Inquisit tasks, I want them to be redirected again to two different Qualtrics URLs based on their original group membership (group 1 goes to one URL, group 2 goes to another). I've got all the other parts working, but cannot seem to make this redirection to different URLs after completion of the Inquisit tasks work, after several attempts at adjusting the code in different ways. Would you be able to help me with this?
Here is my code right now (with fake URLs). Currently it is giving me an error message that says "'script.groupid, 2' The expression contains an unknown property"

// session 1 groups 1 & 2
<batch>
/ file = "corsiblocktappingtask.iqx"
/ file = "group1_vs_group2.iqx"
/ sessions = (1 of 1)
/ onscriptend = [if(script.groupid, 2 == 1) defaults.finishpage = concat("https://syracuseuniversity.qualtrics.com/group1part2"); ]
/ onscriptend = [if(script.groupid, 2 == 2) defaults.finishpage = concat("https://syracuseuniversity.qualtrics.com/group2part2"); ]
</batch>

See contents of the file "group1_vs_group2.iqx" also below. Maybe there is a way to add the different finish page URL to this script, as it's already describing a modification based on group ID?

<include>
/ precondition = [
    mod(script.groupid, 2) == 1;
]
/ file = "digitsymbolsubstitutiontask_test1.iqx"
</include>



/ onscriptend = [if(script.groupid, 2 == 1) defaults.finishpage = concat("https://syracuseuniversity.qualtrics.com/group1part2"); ]
/ onscriptend = [if(script.groupid, 2 == 2) defaults.finishpage = concat("https://syracuseuniversity.qualtrics.com/group2part2"); ]

is wrong, you want something like

/ onscriptend = [if(mod(script.groupid, 2) == 1) defaults.finishpage = concat("https://syracuseuniversity.qualtrics.com/group1part2"); ]
/ onscriptend = [if(mod(script.groupid, 2) == 0) defaults.finishpage = concat("https://syracuseuniversity.qualtrics.com/group2part2"); ]

Thank you so much for your quick reply! I made these adjustments, and now the experiment is running without the error, but still not redirecting to the correct URL for group 1. Instead, both groups are being redirected to the group 2 finish page (which is the one listed as the finish page in my inquisit web experiment settings). Any other help you can provide with redirecting the groups correctly would be greatly appreciated!

For anything further you will need to provide the link to the online study.

Hi Dave, sorry for my ignorance, but what link should I provide to you? the launch page? or is there another link that would allow you access to the actual scripts? My web experiment script name is "GREpredictors" if that helps. Thanks again!

> the launch page?

Yes.

Okay, here is the launch page: https://mili2nd.co/wqxb

Thank you for the link. One issue is the URL specified in the online settings:

Under Inquisit 6 Web, that will always take precendence over anything set by the script(s). That is: If one plans to set the finish URL via some logic in the script, one should always leave the online settings at their default / not specify any external URL there. (This used to be different under Inquisit 5.)

However, there appears to be a bug in the current release 6.3.4 / 6.3.5 that prevents defaults.finishpage from being set properly regardless. I have logged that bug and we'll get that fixed in for either 6.4.0 due out towards the end of the week or 6.4.1 at the latest.

Got it! Thank you so much for your help with this! I appreciate it!

Hi Dave, I was wondering if this bug has been addressed yet? My script redirecting participants to two different external webpages based on group ID still does not seem to be working (even when leaving the setting as default). Thanks!
By Dave - 2/22/2021

abalbert - 2/22/2021
abalbert - 2/9/2021
Dave - 2/8/2021
abalbert - 2/8/2021
Dave - 2/8/2021
abalbert - 2/8/2021
Dave - 2/8/2021
abalbert - 2/8/2021
Dave - 2/8/2021
abalbert - 2/8/2021
Hi Dave/Administrators,
I am new to Inquisit Web and trying to do something similar to the above, but am having difficulty adjusting the script to my needs.
I have an experiment with two groups. They start off at different Qualtrics surveys, and then are sent to Inquisit from there, with participant ID and group ID (either group 1 or group 2) carried forward in the URL. Each group will complete the corsi block task, but only group 1 will complete the digit symbol task. When each group finishes their Inquisit tasks, I want them to be redirected again to two different Qualtrics URLs based on their original group membership (group 1 goes to one URL, group 2 goes to another). I've got all the other parts working, but cannot seem to make this redirection to different URLs after completion of the Inquisit tasks work, after several attempts at adjusting the code in different ways. Would you be able to help me with this?
Here is my code right now (with fake URLs). Currently it is giving me an error message that says "'script.groupid, 2' The expression contains an unknown property"

// session 1 groups 1 & 2
<batch>
/ file = "corsiblocktappingtask.iqx"
/ file = "group1_vs_group2.iqx"
/ sessions = (1 of 1)
/ onscriptend = [if(script.groupid, 2 == 1) defaults.finishpage = concat("https://syracuseuniversity.qualtrics.com/group1part2"); ]
/ onscriptend = [if(script.groupid, 2 == 2) defaults.finishpage = concat("https://syracuseuniversity.qualtrics.com/group2part2"); ]
</batch>

See contents of the file "group1_vs_group2.iqx" also below. Maybe there is a way to add the different finish page URL to this script, as it's already describing a modification based on group ID?

<include>
/ precondition = [
    mod(script.groupid, 2) == 1;
]
/ file = "digitsymbolsubstitutiontask_test1.iqx"
</include>



/ onscriptend = [if(script.groupid, 2 == 1) defaults.finishpage = concat("https://syracuseuniversity.qualtrics.com/group1part2"); ]
/ onscriptend = [if(script.groupid, 2 == 2) defaults.finishpage = concat("https://syracuseuniversity.qualtrics.com/group2part2"); ]

is wrong, you want something like

/ onscriptend = [if(mod(script.groupid, 2) == 1) defaults.finishpage = concat("https://syracuseuniversity.qualtrics.com/group1part2"); ]
/ onscriptend = [if(mod(script.groupid, 2) == 0) defaults.finishpage = concat("https://syracuseuniversity.qualtrics.com/group2part2"); ]

Thank you so much for your quick reply! I made these adjustments, and now the experiment is running without the error, but still not redirecting to the correct URL for group 1. Instead, both groups are being redirected to the group 2 finish page (which is the one listed as the finish page in my inquisit web experiment settings). Any other help you can provide with redirecting the groups correctly would be greatly appreciated!

For anything further you will need to provide the link to the online study.

Hi Dave, sorry for my ignorance, but what link should I provide to you? the launch page? or is there another link that would allow you access to the actual scripts? My web experiment script name is "GREpredictors" if that helps. Thanks again!

> the launch page?

Yes.

Okay, here is the launch page: https://mili2nd.co/wqxb

Thank you for the link. One issue is the URL specified in the online settings:

Under Inquisit 6 Web, that will always take precendence over anything set by the script(s). That is: If one plans to set the finish URL via some logic in the script, one should always leave the online settings at their default / not specify any external URL there. (This used to be different under Inquisit 5.)

However, there appears to be a bug in the current release 6.3.4 / 6.3.5 that prevents defaults.finishpage from being set properly regardless. I have logged that bug and we'll get that fixed in for either 6.4.0 due out towards the end of the week or 6.4.1 at the latest.

Got it! Thank you so much for your help with this! I appreciate it!

Hi Dave, I was wondering if this bug has been addressed yet? My script redirecting participants to two different external webpages based on group ID still does not seem to be working (even when leaving the setting as default). Thanks!

6.4.0 has not been released yet.