Uploaded image for project: 'Moodle'
  1. Moodle
  2. MDL-34257

Quiz attempt popup doesn't respect theme's config.php layout array

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 2.4
    • Fix Version/s: 2.4
    • Component/s: Quiz, Themes
    • Labels:
    • Testing Instructions:
      Hide

      Please test with one or more of the standard themes (this should work in any theme).

      1. As teacher: Create a quiz with "Browser security" set to "Full screen pop-up with some JavaScript security", and "Show blocks during the attempt" turned off.
      2. As student: Attempt the quiz. It should open in a pop-up window. The layout should be very plain:
        • no header
        • no footer
        • no navbar
        • login information shows who is logged in, but no logout link.
        • no real blocks, just the quiz navigation that shows which questions are in the quiz, and the timer (if required).
      3. Now turn on "Show blocks during the attempt" and attempt the quiz again as a student.
      4. Verify the only change to the layout is that now the real blocks (probably navigation and settings) are shown.
      Show
      Please test with one or more of the standard themes (this should work in any theme). As teacher: Create a quiz with "Browser security" set to "Full screen pop-up with some JavaScript security", and "Show blocks during the attempt" turned off. As student: Attempt the quiz. It should open in a pop-up window. The layout should be very plain: no header no footer no navbar login information shows who is logged in, but no logout link. no real blocks, just the quiz navigation that shows which questions are in the quiz, and the timer (if required). Now turn on "Show blocks during the attempt" and attempt the quiz again as a student. Verify the only change to the layout is that now the real blocks (probably navigation and settings) are shown.
    • Affected Branches:
      MOODLE_24_STABLE
    • Fixed Branches:
      MOODLE_24_STABLE
    • Pull from Repository:
    • Pull Master Branch:

      Description

      The base theme sets the config.php's $THEME->layouts to have popup layout with the following settings:
      'popup' => array(
      'file' => 'general.php',
      'regions' => array(),
      'options' => array('nofooter'=>true, 'nonavbar'=>true, 'nocustommenu'=>true, 'nologininfo'=>true),
      ),

      A quiz set to browser security full screen popup with some javascript security ignores all options. The header, footer, navigation and custom menu all show.

      To recreate

      1. set to standard theme
      2. Create a quiz and set the browser security to full screen popup with javascript security
      3. Login as a student in a course with the quiz
      4. Attempt the quiz and see all of the parts of the theme.

        Attachments

        1. afterburner.png
          23 kB
          David Monllaó
        2. Math203Y3S2_ Linear Inequalities Quiz.png
          65 kB
          Jason Hardin
        3. pop up quiz.png
          43 kB
          Adrian Greeve

          Issue Links

            Activity

              People

              Assignee:
              timhunt Tim Hunt
              Reporter:
              jrh18 Jason Hardin
              Integrator:
              Sam Hemelryk
              Tester:
              Adrian Greeve
              Participants:
              Component watchers:
              Tim Hunt, Andrew Nicols, Jun Pataleta, Michael Hawkins, Shamim Rezaie, Simey Lameze, Bas Brands
              Votes:
              1 Vote for this issue
              Watchers:
              7 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:
                Fix Release Date:
                3/Dec/12