Display Question ID (as Piped Text?) in Header | XM Community
Solved

Display Question ID (as Piped Text?) in Header

  • 25 July 2023
  • 8 replies
  • 63 views

Userlevel 2
Badge +3

Hi! For some reasons I would like to show my question ID in the header (in very small characters below the question and less remarkable to the participants). I tried to do it by inserting a Piped Text in the Header section of Look&Feel but could not find the according field name for the question ID. Is there any way to do it? Many thanks!

icon

Best answer by rondev 25 July 2023, 16:22

View original

8 replies

Userlevel 3
Badge +11

I don’t think you can do this with piped text. But since this would be a fixed value for each question, does it have to be piped text? Can’t you just add it manually?

Userlevel 4
Badge +12

you can use javascript code and insert the pipetext there in header/footer of theme option.

Userlevel 2
Badge +3

OK. Its a bit complicated to explain. I could just activate “show question number” in the settings. But is there any way to modify the font and position of this question number? I don’t want it to be displayed in front of the question. I need it somewhere at the bottom of the page and in small characters… I guess there should be a way to do it with Java but I am not familiar with it...

Userlevel 7
Badge +22

Use the below code in header with Show Question number enabled.

<script>
Qualtrics.SurveyEngine.addOnReady(function()
{var det_elem = jQuery(".ExportTag").detach();jQuery("#Footer").html(det_elem).css({"text-align":"center","font-size":"smaller"});});
</script>

 

Userlevel 2
Badge +3

@rondev Oh great, thank you so much!

Userlevel 2
Badge +3

@rondev Sorry for asking again. In my survey I need a logo and a text in the footer. Here is its code:

<table border="0" cellpadding="1" cellspacing="1" height="96" width="705">
<tbody>
<tr>
<td><img height="83" src="https://MyURL" width="192" /></td>
<td>MyText</td>
</tr>
</tbody>
</table>

Additionally, I need the question ID below or above this. If I add your script in the header section, I get the question ID but the logo in the footer disappears completely. Is there any way to have both - the footer+text and the question ID? Many thanks in advance!

Userlevel 7
Badge +22

Use the below code in header with Show Question number enabled.

<script>
Qualtrics.SurveyEngine.addOnReady(function()
{var det_elem = jQuery(".ExportTag").detach();jQuery("#Footer").append(det_elem).css({"text-align":"center","font-size":"smaller"});});
</script>
Userlevel 2
Badge +3

@rondev Thanks!

Leave a Reply