Pre-installing the Inquisit Web Plugin


Author
Message
seandr
seandr
Supreme Being (120K reputation)Supreme Being (120K reputation)Supreme Being (120K reputation)Supreme Being (120K reputation)Supreme Being (120K reputation)Supreme Being (120K reputation)Supreme Being (120K reputation)Supreme Being (120K reputation)Supreme Being (120K reputation)
Group: Administrators
Posts: 1.3K, Visits: 1K
When running Inquisit web experiments in conjunction with other tools such as Survey Monkey and Qualtrics, it may be desirable to ask participants to download the plugin at the very beginning of the data collection process as opposed to waiting until they reach the Inquisit task. This allows participants to decide upfront whether they are willing to install the plugin, and if they do, it provides a smoother experience once they reach the Inquisit part of the experiment. 

To accomplish this, you can provide a smart link to the plugin installer at the beginning of the study. The link will need to determine whether the participant is running Windows or Mac, and if they are running Windows, whether they are using the IE browser or Chrome/Firefox/Safari. It can then point to the appropriate version of the plugin. Below is a snippet of HTML and Javascript that accomplishes exactly that:


<script type="text/javascript">
    function downloadInquisit() {
        try {
            var pluginUrl = "http://www.millisecond.com/download/4/4_0_6_0/";
            var agent = navigator.userAgent.toLowerCase();
            if ((agent.indexOf("msie") != -1 && agent.indexOf("opera") == -1) || agent.indexOf("trident") != -1) {
                pluginUrl += "ax/win32/InquisitAx.exe";
            }
            else {
                if (navigator.platform.indexOf("Mac") != -1 || navigator.userAgent.indexOf("Mac OS X") != -1) {
                    pluginUrl += "np/mac/Inquisit_Plugin_4060.dmg";
                }
                else {
                    pluginUrl += "np/win32/npInquisit.exe";
                }
            }
            window.location.href = pluginUrl;
        }
        catch (e) {
            window.alert("Error: " + e.Message);
        }

    }
</script>
<a href="javascript:downloadInquisit()">Download Inquisit Plugin</a>

Just copy and paste the above code into the web page where you want to enable pre-installing the plugin. Note - this example assumes you are using Inquisit 4.0.6.0. If you've registered the script with a different version, you'll need to change the code to match the version you are using or this will not work.The version number appears twice in the code snippet above and is highlighted in yellow.





Edited 6 Years Ago by seandr
LC
LC
Partner Member (862 reputation)Partner Member (862 reputation)Partner Member (862 reputation)Partner Member (862 reputation)Partner Member (862 reputation)Partner Member (862 reputation)Partner Member (862 reputation)Partner Member (862 reputation)Partner Member (862 reputation)
Group: Forum Members
Posts: 6, Visits: 123
Hi everyone

I was referred to this thread in response to my question on launch page translations. I tried to include the above code in my survey to allow a pre-install on a survey page with instructions in the participants' native language. Unfortunately, the link underneath "Download Inquisit plug-in" appears to be dead. I changed nothing but the version number to 4.0.8. When I simply copy/paste the plug-in URL link (http://www.millisecond.com/download/4/4_0_8_0/) into my browser it gives me an "access denied" error message. Could that mean something is wrong with the download link itself?

The code I use:

<script type="text/javascript">
    function downloadInquisit() {
        try {
            var pluginUrl = "http://www.millisecond.com/download/4/4_0_8_0/";
            var agent = navigator.userAgent.toLowerCase();
            if ((agent.indexOf("msie") != -1 && agent.indexOf("opera") == -1) || agent.indexOf("trident") != -1) {
                pluginUrl += "ax/win32/InquisitAx.exe";
            }
            else {
                if (navigator.platform.indexOf("Mac") != -1 || navigator.userAgent.indexOf("Mac OS X") != -1) {
                    pluginUrl += "np/mac/Inquisit_Plugin_4080.dmg";
                }
                else {
                    pluginUrl += "np/win32/npInquisit.exe";
                }
            }
            window.location.href = pluginUrl;
        }
        catch (e) {
            window.alert("Error: " + e.Message);
        }

    }
</script>
<a href="downloadInquisit()">Download Inquisit Plugin</a>

Dave
Dave
Supreme Being (871K reputation)Supreme Being (871K reputation)Supreme Being (871K reputation)Supreme Being (871K reputation)Supreme Being (871K reputation)Supreme Being (871K reputation)Supreme Being (871K reputation)Supreme Being (871K reputation)Supreme Being (871K reputation)
Group: Administrators
Posts: 10K, Visits: 62K
Try the attached code.

To test it, you can go to

http://www.w3schools.com/js/tryit.asp?filename=tryjs_myfirst

Empty the editor window on the left-hand side, paste the entire contents of the attached file in the window and click "See Result>>".

A link named "Download Inquisit Plugin" will appear in the output window on the right. Clicking it will start the download of a plugin version suitable for your browser.
Attachments
smartlink.txt (271 views, 978 bytes)
Dave
Dave
Supreme Being (871K reputation)Supreme Being (871K reputation)Supreme Being (871K reputation)Supreme Being (871K reputation)Supreme Being (871K reputation)Supreme Being (871K reputation)Supreme Being (871K reputation)Supreme Being (871K reputation)Supreme Being (871K reputation)
Group: Administrators
Posts: 10K, Visits: 62K
Since I think it would be preferable to install the Web Player under most circumstances, you can find an alternate version of the code attached that does just that.

Attachments
smartlink_webplayer.txt (354 views, 996 bytes)
Edited 5 Years Ago by Dave
LC
LC
Partner Member (862 reputation)Partner Member (862 reputation)Partner Member (862 reputation)Partner Member (862 reputation)Partner Member (862 reputation)Partner Member (862 reputation)Partner Member (862 reputation)Partner Member (862 reputation)Partner Member (862 reputation)
Group: Forum Members
Posts: 6, Visits: 123
Hi Dave

Thanks again. I have 2 problems though:

1) The scripts work on the test website, but not in my survey (hosted at SurveyGizmo). When I click the links nothing happens. I have no clue why, and I find it particularly strange because another JavaScript (on another survey page) works fine.
2) The Launch Page normally detects the browser and OS in order to determine the required version of Inquisit, right? So I suppose that if I use the pre-install links, I will always need to include links to all installation files and let survey takers decide which version they need? If so, I think I will just use the Launch Page to avoid too much drop-out because of "technicalities".

Dave
Dave
Supreme Being (871K reputation)Supreme Being (871K reputation)Supreme Being (871K reputation)Supreme Being (871K reputation)Supreme Being (871K reputation)Supreme Being (871K reputation)Supreme Being (871K reputation)Supreme Being (871K reputation)Supreme Being (871K reputation)
Group: Administrators
Posts: 10K, Visits: 62K
Re. #1: This sounds like something SurveyGizmo support would be best equipped to handle. If have no insight into whether they place any constraints on "custom" JavaScript on their platform, their support people however, should be able to assist in that regard.
Re. #2: The JavaScript code for the "smart link" does browser and OS sniffing to determine the correct download and adjusts the download link accordingly. There should be no need for providing additional links / having the participants make the determination themselves. You would only need to resort to that in case you can't get the "smart link" to work on SurveyGizmo's platform (cf. #1 above).

LC
LC
Partner Member (862 reputation)Partner Member (862 reputation)Partner Member (862 reputation)Partner Member (862 reputation)Partner Member (862 reputation)Partner Member (862 reputation)Partner Member (862 reputation)Partner Member (862 reputation)Partner Member (862 reputation)
Group: Forum Members
Posts: 6, Visits: 123
Okay. I'll check with SurveyGizmo support then. Thanks!
Dave
Dave
Supreme Being (871K reputation)Supreme Being (871K reputation)Supreme Being (871K reputation)Supreme Being (871K reputation)Supreme Being (871K reputation)Supreme Being (871K reputation)Supreme Being (871K reputation)Supreme Being (871K reputation)Supreme Being (871K reputation)
Group: Administrators
Posts: 10K, Visits: 62K
Please let me know what their response is. I might be able to assist in getting things working then.

Wahideh
Wahideh
New Member (2 reputation)New Member (2 reputation)New Member (2 reputation)New Member (2 reputation)New Member (2 reputation)New Member (2 reputation)New Member (2 reputation)New Member (2 reputation)New Member (2 reputation)
Group: Forum Members
Posts: 1, Visits: 11
seandr - 6/19/2014
When running Inquisit web experiments in conjunction with other tools such as Survey Monkey and Qualtrics, it may be desirable to ask participants to download the plugin at the very beginning of the data collection process as opposed to waiting until they reach the Inquisit task. This allows participants to decide upfront whether they are willing to install the plugin, and if they do, it provides a smoother experience once they reach the Inquisit part of the experiment. 

To accomplish this, you can provide a smart link to the plugin installer at the beginning of the study. The link will need to determine whether the participant is running Windows or Mac, and if they are running Windows, whether they are using the IE browser or Chrome/Firefox/Safari. It can then point to the appropriate version of the plugin. Below is a snippet of HTML and Javascript that accomplishes exactly that:


<script type="text/javascript">
    function downloadInquisit() {
        try {
            var pluginUrl = "http://www.millisecond.com/download/4/4_0_6_0/";
            var agent = navigator.userAgent.toLowerCase();
            if ((agent.indexOf("msie") != -1 && agent.indexOf("opera") == -1) || agent.indexOf("trident") != -1) {
                pluginUrl += "ax/win32/InquisitAx.exe";
            }
            else {
                if (navigator.platform.indexOf("Mac") != -1 || navigator.userAgent.indexOf("Mac OS X") != -1) {
                    pluginUrl += "np/mac/Inquisit_Plugin_4060.dmg";
                }
                else {
                    pluginUrl += "np/win32/npInquisit.exe";
                }
            }
            window.location.href = pluginUrl;
        }
        catch (e) {
            window.alert("Error: " + e.Message);
        }

    }
</script>
<a href="downloadInquisit()">Download Inquisit Plugin</a>

Just copy and paste the above code into the web page where you want to enable pre-installing the plugin. Note - this example assumes you are using Inquisit 4.0.6.0. If you've registered the script with a different version, you'll need to change the code to match the version you are using or this will not work.The version number appears twice in the code snippet above and is highlighted in yellow.




Hi, I just changed the script above to match it to version 5 (5.0.14.0). I get an error that the page is not found. Version 4.0.6.0 does however work! Could you please let me know what is going wrong? Thanks in advance!

GO

Merge Selected

Merge into selected topic...



Merge into merge target...



Merge into a specific topic ID...




Reading This Topic

Explore
Messages
Mentions
Search