I want to add headers to the matrix table(bipolar); I checked the 'position text above' option since participants need to slide on their mobile version otherwise. I'm trying to create 7-point semantic differentials with headers/labels on top of the statements(from 1 to 7). I googled jQuery code and tried several times, but it did not work out for me. I've attached an example picture to explain what I would like to make. Any suggestions would be a great help - Thank you in advance!
Hi there, while I am not sure how to add a header row that contains Numbers to a Matrix Bipolar question with Position Text Above, a similar effect might be achieved by making the radio buttons a bit larger and then placing the Number labels within them.
To try this, add the below to the Matrix question's JavaScript in the OnReady section:
jQuery("#"+this.questionId+" label.q-radio").css({
"width":"1.6em",
"height":"1.6em",
"line-height":"1.6em"
});
jQuery("#"+this.questionId+" td:nth-child(1) > label").html("1");
jQuery("#"+this.questionId+" td:nth-child(2) > label").html("2");
jQuery("#"+this.questionId+" td:nth-child(3) > label").html("3");
jQuery("#"+this.questionId+" td:nth-child(4) > label").html("4");
jQuery("#"+this.questionId+" td:nth-child(5) > label").html("5");
jQuery("#"+this.questionId+" td:nth-child(6) > label").html("6");
jQuery("#"+this.questionId+" td:nth-child(7) > label").html("7");
Modifying the method used in this thread would be a good starting point if anyone needs to create a header row that contains Numbers, but I think I still lean towards putting the numbers in the radio buttons.
Leave a Reply
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.