Solved
A Validation Error resfreshes the page and JavaScript won't execute. Why?
I use this code in JavaScript to hide the PreviousButton on a page:
Qualtrics.SurveyEngine.addOnload(function() {
jQuery("input#PreviousButton.PreviousButton.Button").css("display", "none");
});
I use this code on the first question of the block, no page break, and put it in addOnload, addOnready, addOnunload.
However, one of the question has a validation parameter. When this validation is not met and the NextButton is pressed, the page reloads and the PreviousButton is back.
Why is that so and how to fix it?
Best answer by JosephK
I had a similar problem but fixed it (albeit in a hacky way) by putting the code inside a timer
See https://www.qualtrics.com/community/discussion/comment/37570#Comment_37570
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.
