Put question text to the left of autocomplete text box | XM Community
Question

Put question text to the left of autocomplete text box

  • 26 April 2021
  • 4 replies
  • 28 views

I would like to put the question text to the left of the autocomplete text box (see picture below - I would like to move the "2." to the left on the same line). Is this possible to do with JS?

Screen Shot 2021-04-26 at 4.29.30 PM.png


4 replies

Userlevel 7
Badge +21

Reduce the size of your text box. It'll fit automatically.
Or move to a form type question.

Thanks ahmedA! Unfortunately resizing the text box doesn't move the question text and the form type question doesn't support autocomplete text boxes. Any other ideas on how to do this?
Really appreciate it!

Userlevel 7
Badge +21

Can you share the survey link?

Userlevel 2
Badge +3

Hey Adamg
This CSS code worked for me. Note that it changes the formatting for all Text Entry Single-Line questions.
.Skin .TE .SL legend {
    float: left;
width: auto;
}


.Skin .TE .SL legend + div.QuestionBody {
padding: 20px
}

If you don't want to apply the formatting to all Text Entry Single-Line questions, you could use the following JS code to modify just that specific question:

Qualtrics.SurveyEngine.addOnReady(function()
{
    QID = this.questionId;
jQuery('#' + QID + ' legend').css('width','auto');
jQuery('#' + QID + ' legend').css('float','left');
jQuery('#' + QID + ' .QuestionBody').css('padding','20px');
});



Leave a Reply