Moodle
  1. Moodle
  2. MDL-31019

Quiz with Javascript Security Enabled does not show results

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Minor Minor
    • Resolution: Fixed
    • Affects Version/s: 2.2
    • Fix Version/s: 2.2.2
    • Component/s: Quiz
    • Labels:
    • Environment:
      Any latest version of IE, Chrome, or Firefox
    • Database:
      Any
    • Testing Instructions:
      Hide

      1) Create a quiz
      2) Set it to use a pop-up secure window
      3) Take the quiz and click Submit all and finish.
      4) Verify that there are no fatal errors.

      Show
      1) Create a quiz 2) Set it to use a pop-up secure window 3) Take the quiz and click Submit all and finish. 4) Verify that there are no fatal errors.
    • Affected Branches:
      MOODLE_22_STABLE
    • Fixed Branches:
      MOODLE_22_STABLE
    • Pull from Repository:
    • Pull Master Branch:

      Description

      When a student submits a quiz, they do not see the results screen. Depending on the browser, they will either get a HTTP 500 error (IE and Chrome), or just a blank screen (FireFox). Turning off browser security for the quiz makes it work fine. I noticed that the same issued was raised in Moodle 2.1 (MDL-28424), and was fixed, but it looks like it is back in Moodle 2.2.

        Gliffy Diagrams

          Activity

          Hide
          Tim Hunt added a comment -

          Please turn on Debugging (http://docs.moodle.org/22/en/Debugging) so we get a real error message. The fix for MDL-28424 was applied to 2.2 as well as 2.1.

          Show
          Tim Hunt added a comment - Please turn on Debugging ( http://docs.moodle.org/22/en/Debugging ) so we get a real error message. The fix for MDL-28424 was applied to 2.2 as well as 2.1.
          Hide
          Mike Clendenen added a comment -

          In IE 9, Firefox 9, and Chrome 16, this is the error that shows up after reviewing the results (at least the results are now showing up):

          Fatal error: Call to undefined function html_writer() in /home/twooh/public_html/mod/quiz/renderer.php on line 492

          The student is left with the secure browser window open. If you close the window, you see the "Attempt Quiz" button/screen.

          Show
          Mike Clendenen added a comment - In IE 9, Firefox 9, and Chrome 16, this is the error that shows up after reviewing the results (at least the results are now showing up): Fatal error: Call to undefined function html_writer() in /home/twooh/public_html/mod/quiz/renderer.php on line 492 The student is left with the secure browser window open. If you close the window, you see the "Attempt Quiz" button/screen.
          Hide
          Tim Hunt added a comment -

          Thanks for the extra information. Should be easy to fix now.

          Show
          Tim Hunt added a comment - Thanks for the extra information. Should be easy to fix now.
          Hide
          Sam Hemelryk added a comment -

          Thanks Tim, this has been integrated now

          Show
          Sam Hemelryk added a comment - Thanks Tim, this has been integrated now
          Hide
          Andrew Davis added a comment -

          All seems to work as promised.

          Show
          Andrew Davis added a comment - All seems to work as promised.
          Hide
          Mike Clendenen added a comment -

          Thanks for working on this.

          Does the fix involve more than the changes to the mod/quiz/renderer.php file? I made those changes to our Moodle 2.2. Now after closing the quiz, I see this:

          http://twooh.pittcc.edu/mod/quiz/view.php?id=300
          This window will close shortly.

          This is better than before since I did not see anything. However, the window never closes. Of course, if there is more to it than just the changes to renderer.php, then pardon my intrusion <grin>.

          Mike

          Show
          Mike Clendenen added a comment - Thanks for working on this. Does the fix involve more than the changes to the mod/quiz/renderer.php file? I made those changes to our Moodle 2.2. Now after closing the quiz, I see this: http://twooh.pittcc.edu/mod/quiz/view.php?id=300 This window will close shortly. This is better than before since I did not see anything. However, the window never closes. Of course, if there is more to it than just the changes to renderer.php, then pardon my intrusion <grin>. Mike
          Hide
          Tim Hunt added a comment -

          It is just the change in the renderer file. I don't know why the JavaScript that should close the window is not working.

          Are there any JavaScript errors displayed?

          Show
          Tim Hunt added a comment - It is just the change in the renderer file. I don't know why the JavaScript that should close the window is not working. Are there any JavaScript errors displayed?
          Hide
          Eloy Lafuente (stronk7) added a comment -

          This virus has been spread upstream, everybody will be infected soon. Congrats, you did it!

          Closing, ciao

          Show
          Eloy Lafuente (stronk7) added a comment - This virus has been spread upstream, everybody will be infected soon. Congrats, you did it! Closing, ciao
          Hide
          Mike Clendenen added a comment -

          Tim:

          I do not see any Javascript errors, just the message that this window will close.

          Eloy:

          What virus are you referring to?

          Show
          Mike Clendenen added a comment - Tim: I do not see any Javascript errors, just the message that this window will close. Eloy: What virus are you referring to?
          Hide
          Tim Hunt added a comment -

          The virus was an in-joke. Eloy always uses bizarre messages when closing bugs at the end of the weekly development cycle.

          Show
          Tim Hunt added a comment - The virus was an in-joke. Eloy always uses bizarre messages when closing bugs at the end of the weekly development cycle.

            People

            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: