Placing a $ sign in front of a text box | XM Community
Skip to main content

Placing a $ sign in front of a text box


Hello,
I've seen some discussion regarding placing a dollar sign to display infront of a text box but for me the $ sign appears on the line above the text box, not before it.
Can anyone help with this?
Thank you.
Ash.

4 replies

MatthewM
Level 6 ●●●●●●
Forum|alt.badge.img+30
  • Level 6 ●●●●●●
  • 1069 replies
  • July 23, 2020

Hi ashio,
Is this happening in a single text field, Matrix table, or something else? Can you share the Javascript you used?


  • Author
  • 2 replies
  • July 23, 2020

Hello,
It's in a single text field. I used:
Qualtrics.SurveyEngine.addOnload(function()
{ jQuery("#"+this.questionId+" .InputText").before("$");
});


rondev
Level 6 ●●●●●●
Forum|alt.badge.img+22
  • Level 6 ●●●●●●
  • 1449 replies
  • July 23, 2020

Use the below code:
jQuery("#"+this.questionId+" .InputText").css("width","96%").before("$");


  • Author
  • 2 replies
  • July 24, 2020

Thank you for the response but that still puts the $ sign on the row above the text box (see attached).
Screen Shot 2020-07-23 at 9.52.00 AM.png


Leave a Reply