Dear Andy, to handle this, I added the following code to all questions in the next block(s):Qualtrics.SurveyEngine.addOnload(function(){ /*Place your JavaScript here to run when the page loads*/var header = document.createElement("div"); header.className = "header" header.id = "header_1"; var timer = document.createElement("div"); timer.className = "timer"; timer.id = "timer_1"; document.getElementById("timer_1").innerHTML = "   "});Qualtrics.SurveyEngine.addOnReady(function(){ /*Place your JavaScript here to run when the page is fully displayed*/});Qualtrics.SurveyEngine.addOnUnload(function(){ /*Place your JavaScript here to run when the page is unloaded*/});Actually, it just displays a blank space where the timer was displayed before. Hopefully, that helps.Best wishes
Hi @npetrov937 , that's really great, it worked :-)!! Thank you so very much for your great and kind support and your time!!
Hi @npetrov937 , Many thanks for your kind response. I implemented the following: 1) I added the variable "timeRemaining" = 10 as embedded data in the survey flow 2) I added the following JavaScript to the first question of the block: Qualtrics.SurveyEngine.addOnload(function() { var header = document.createElement("div"); header.className = "header" header.id = "header_1"; var timer = document.createElement("div"); timer.className = "timer"; timer.id = "timer_1"; timer.innerHTML = "Time Remaining: <span id='time'>00:10</span>"; header.appendChild(timer); document.body.insertBefore(header, document.body.firstChild); function startTimer(duration, display) { var timer = duration, minutes, seconds; var myTimer = setInterval(function() { Qualtrics.SurveyEngine.setEmbeddedData('timeRemaining', timer); minutes = parseInt(timer / 60, 10) seconds = par
Already have an account? Login
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.
Sorry, we're still checking this file's contents to make sure it's safe to download. Please try again in a few minutes.
Sorry, our virus scanner detected that this file isn't safe to download.