Change Text of "Next Button" based on language code | XM Community
Solved

Change Text of "Next Button" based on language code

  • 7 July 2021
  • 7 replies
  • 250 views

Badge +1

Hi everyone,
I would like to change the label/text of the last button of my survey to "Send Survey" also for other languages. I just learned how to do it for the entire survey by using JavaScript (see below).
jQuery('#NextButton').val('Send Survey');
I need a different text based on the selected language. I assume that it has to be something like a "If...then" depending on embedded data. Can anyone advise?
Thanks.
Jack.

icon

Best answer by grahulp5 12 July 2021, 23:49

View original

7 replies

Userlevel 4
Badge +13

Use this in header of the script:

var a=Qualtrics.SurveyEngine.getEmbeddedData('Next') //here next is the variable used to store value for next button/ can be a pipe-in for translations
jQuery('#NextButton').val(a)

and then update the embedded variable or use that as a pipe-in from survey level itself.

Badge +1

Hi grahulp5.
Thanks a lot. It worked perfectly.

Badge +6

@grahulp5 How can we add message from Library to embedded data.

Userlevel 4
Badge +13

https://community.qualtrics.com/XMcommunity/discussion/comment/42516#Comment_42516You just need to simply add your message in library then use pipe text in survey flow to pipe it in embedded data.

Badge +6

grahulp5 Thank you so much for your reply, but I didn't find any option to pipe the message from message library to embedded data. Only below options we are getting to pipe. Please suggest.
image.png

Userlevel 4
Badge +13

https://community.qualtrics.com/XMcommunity/discussion/comment/43081#Comment_43081MadhurSingh I couldn't find anything to get text from library. You can either use a docx or image/video to be piped.

Badge +6

grahulp5 Thank you so much for your efforts. Yes, I used the same approach you shared.

Leave a Reply