• Resolved Stefanowitz

    (@stefanowitz)


    When option “Correct Answer Display” is enabled the user can still change his choice to the correct answer after each question’s answer is displayed. The radio buttons should be disabled as soon as user clicks “Show Answer”. Is there a quick fix for this?

    Thanks!

Viewing 7 replies - 1 through 7 (of 7 total)
  • Plugin Author Bob

    (@prasunsen)

    This option is not supposed to be secure and used for exams. For a secure option you need the pro version.

    Thread Starter Stefanowitz

    (@stefanowitz)

    Well, it doesn’t need to be secure just nook “look broken” and being able to change votes after the answer has been selected and the correct/incorrect answers have been highlighted just looks broken.

    Isn’t there a simple JS fix to just disable all inputs after the “show answer” button has been clicked?

    Buying the pro version would be totally ok but I checked the demo of the pro version but the backend seemed totally different for me, much more powerful of course but also with the focus on exams and tests and not on simple quizes, it seemed more difficult to setup compared to the simple free version.

    Plugin Author Bob

    (@prasunsen)

    We’ll consider doing it but it’s not something that we can work on right now. The only way to change the behavior is changing the code directly.

    Thread Starter Stefanowitz

    (@stefanowitz)

    Changing the code directly would be totally ok, I would just need to know which file / function to modifiy. Thanks a lot!!

    Plugin Author Bob

    (@prasunsen)

    script.js function Watu.showAnswer

    I think it would be here:

    jQuery(".answer-"+Watu.current_question).each(function(i) {
    		if(this.checked && this.className.match(/js\-answer/)) {			
    			var number = this.id.toString().replace(/\D/g,"");
    			if(number) {
    				jQuery("#answer-label-"+number).addClass("user-answer");
    			}
    		}
    	});

    Most likely adding an else-case where to set this.disabled=true, but I am speaking without trying it so it’s just a guess.

    Thread Starter Stefanowitz

    (@stefanowitz)

    Thanks a ton, that hint was all I needed!!

    For those who are interested in this: just add this line of code in file “scripts.js”, right after line 112:

    jQuery("input.answer-"+Watu.current_question).attr("disabled",true);

    Thanks for the fantastic & fast support. Just gave your plugin a glowing 5/5 review, love it!

    Merry X-Mas ??

    Plugin Author Bob

    (@prasunsen)

    Thank you. We’ll test the code from your feedback and will apply it.

    Merry X-mas to you too!

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘“Correct Answer Display” breaks quiz’ is closed to new replies.