Is there a way to apply a background to question groups? | XM Community
Question

Is there a way to apply a background to question groups?


Badge

I have a groups of the same questions for different categories, and it would be nice to have them displayed together but in some sort of container to distinguish from other groups. I tried using blocks but wasn't a fan of having to make users go to new pages for each block since I have 5 groups.
I've been playing around with the themes and styling of my survey but haven't found any option to do this. Is there any way to have like a border outlining a group of questions?


4 replies

Userlevel 6
Badge +27

Hi!!
I think you cando that with custom CSS, but there inst a native way to do it on the look and feel menu

Userlevel 7
Badge +27

The easiest way would be to use JavaScript to change the question background color for each question in the group:
jQuery("#"+this.questionId).css("background-color","#BBE6FF");

Badge

Gotcha, thanks Ana and Tom for the insight.
Tom, is it possible to configure that JS snippet to apply to any elements at the same layer? I forget the proper terminology, but I'm thinking of applying the same CSS to all the different groupings.

Userlevel 7
Badge +27

bkimup - You would have to have some way of identifying what questions are to be grouped together. You could embed some html in the question text to do that. Then you could use one JavaScript to set the background of all the questions, but that JS would be much more complicated. Bottom line is that it is probably more effort than just adding the single line of JS to each question as I proposed above.

Leave a Reply