Has any cracked the code to modify the slider scale to dollars? I'm hoping to modify to $0 to $100,000.
Any ideas?
Chipper 🧐
Solved
Amending slider question scale?
Best answer by qualtrics_nerd
Hi
Yes, you can achieve that by updating the parameter inside localeString(‘en-IN’) to localeString(‘en-US’) , Below is the updated code:
Qualtrics.SurveyEngine.addOnload(function()
{
/*Place your JavaScript here to run when the page loads*/
});
Qualtrics.SurveyEngine.addOnReady(function()
{
const numbers = document.querySelectorAll(".numbers li");
numbers.forEach(function(li) {
const num = li.textContent.trim();
const formattedNum = Number(num).toLocaleString('en-US');
li.textContent = "$" + formattedNum;
});
});
Qualtrics.SurveyEngine.addOnUnload(function()
{
/*Place your JavaScript here to run when the page is unloaded*/
});Hope this resolves your query😊!!!
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.
