I need people to list the names of all their social connections. While some might have only one, others might have dozens. Is there a way to create a text entry box and below it include a "add another" option, so people can add as many connections as they want?
One option would be to use the Text entry question and use either multi line or essay. If its a multiple choice question, you can allow text entry and after that change the text entry size to medium to allow for multi line inputs.
I previously found this on the Community. It is currently setup for a Matrix item and I'm not sure how to get it to work on Multiple Choice. But it could work if on the left side you have Social Connection 1, Social Connection 2, etc. Then on the top just do one column for name.
FYI, you need to create as many rows as you are willing to allow, this code merely hides them until the button is clicked.
Qualtrics.SurveyEngine.addOnload(function()
{
var that=this.questionId;
jQuery("#"+this.questionId+" tr.Choice:not(:lt(3))").hide();
jQuery("").insertAfter("#"+this.questionId+" tr.ChoiceRow:last");
jQuery("#add").on('click',function(){
var c= jQuery("tr.Choice:visible").length;
jQuery("#"+that+" tr.Choice:eq("+c+")").show();
});
})
Qualtrics.SurveyEngine.addOnReady(function()
{
/*Place your JavaScript here to run when the page is fully displayed*/
});
Qualtrics.SurveyEngine.addOnUnload(function()
{
/*Place your JavaScript here to run when the page is unloaded*/
});"
Leave a Reply
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.