I want to have a counter display that counts up by 27 seconds each second. I have this JavaScript code...but I can't get it to work in Qualtrics. I am guessing I am missing something that Qualtrics requires? Any advice?
Thanks so much!
Qualtrics.SurveyEngine.addOnload(function()
{
var seconds = 0;
var el = document.getElementById('seconds-counter')
function incrementSeconds() {
seconds += 27;
el.innerText = "You have been here for " + seconds + " seconds.";
var cancel = setInterval(incrementSeconds, 1000);
});
});
Question
adding javascript
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.
