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

Quiz attempts - Indicate the question that answers belong to

XMLWordPrintable

    • MOODLE_400_STABLE, MOODLE_401_STABLE
    • MOODLE_400_STABLE, MOODLE_401_STABLE
    • MDL-76849-401-5
    • MDL-76849-master-5
    • Hide

      Setup

      1. Log in as an admin.
      2. Install the following plugins to your Moodle instance:
      3. Go to Site administration > Plugins > Filters > Manage filters
      4. Enable the Embed questions filter.
      5. Go to Site administration > Plugins > Text editors > Atto HTML editor > Atto toolbar settings
      6. On the "Toolbar config", add "embedquestion" to the "{{insert = }}" line.
      7. Save the changes.
      8. Restore the backup course quiz_examples.mbz .
      9. (master only) Go to the Questions tab of the Demo quiz activity. Customise one or more question numbers (eg. Q1, Q2, etc).

      Test

      Quiz
      1. Log in as a student
      2. Attempt the quiz
      3. On the quiz attempt page, open your browser dev tools, and inspect the accessible label of the answer fields for each question.
        Note: You can inspect the labelling of the elements either by:
        • (Easiest) Clicking on the upper left button that enables the user to highlight elements on the page (Called "Pick an accessible object from the page" on Firefox and "Select an element to inspect it" on Chrome/Chromium-based browsers)
        • Inspecting the accessibility tree through the browser dev tools (Chrome, Firefox)
      4. Confirm that the text input fields indicate the question number that the question belongs to.
        • Radio buttons and checkboxes will be in fieldsets with a legend that indicates the question number when inspected. e.g. "Question x Select one:" or "Question x Select one or more:" for multiple choice questions and "Multiple choice x Question y" for multiple choice items in Cloze questions
        • Questions with multiple select elements will have an accessible label with the format "Answer x Question y"
        • Questions with text input answer fields will have an accessible label with the format "Answer Question x"
        • The blank fields for drag and drop into text question types will have an accessible label with the format "Blank x Question y"
        • The text area element for essay questions will have an accessible label with the format "Answer text Question x"
        • The file picker element for essay questions will have an accessible label with the format "Answer files Question x"
      5. Confirm that for questions with customised question numbers, the question number shown on the answer fields' accessible label indicates the displayed customised question number. E.g. if a short answer question has a question number of "QS1", the accessible label of the answer field will be something like "Answer, question QS1"
      6. Answer the questions and press "Finish attempt..."
      7. Submit the quiz attempt and proceed to the next page (Review page)
      8. Check the accessible labels of the answer fields on the review page and confirm that the question number is indicated as well for the answer fields.
      Third-party plugins: Student quiz
      1. As a student, go to Student quiz 1.
      2. Start the quiz
      3. Go through each question and inspect the accessible label of the answer fields for each question.
        Note: You must rate each question before clicking on to the next question
        N
      4. Confirm that the question number is indicated on the accessible label of the answer fields.
      Third-party plugins: Embed questions filter
      1. Make sure you're using the Atto editor as your default editor.
      2. Create a Page resource.
      3. Name this as "Embedded questions page"
      4. On the Content field, expand the toolbar and click on the "Embed question" button (its icon looks like a checklist).
      5. On the "Embed question" modal, select "Default for QE [QE] (20)"
      6. On the question field, select any question (e.g. Cloze 2) then press "Embed question"
      7. Repeat the process to embed about two or more questions (e.g. a short answer, multichoice, etc.).
      8. Save and display the page.
        • You might see debugging notices like "Invalid event functions defined in \filter_embedquestion\event\question_started". Ignore this.
      9. Check the accessible label of the answer fields.
      10. Confirm that the question number is not indicated on the accessible label of the answer fields.
      Show
      Setup Log in as an admin. Install the following plugins to your Moodle instance: Embed questions filter Embed question atto button StudentQuiz Go to Site administration > Plugins > Filters > Manage filters Enable the Embed questions filter. Go to Site administration > Plugins > Text editors > Atto HTML editor > Atto toolbar settings On the " Toolbar config ", add " embedquestion " to the "{{insert = }}" line. Save the changes. Restore the backup course quiz_examples.mbz . (master only) Go to the Questions tab of the Demo quiz activity. Customise one or more question numbers (eg. Q1, Q2, etc). Test Quiz Log in as a student Attempt the quiz On the quiz attempt page, open your browser dev tools, and inspect the accessible label of the answer fields for each question. Note: You can inspect the labelling of the elements either by: (Easiest) Clicking on the upper left button that enables the user to highlight elements on the page (Called "Pick an accessible object from the page" on Firefox and "Select an element to inspect it" on Chrome/Chromium-based browsers) Inspecting the accessibility tree through the browser dev tools ( Chrome , Firefox ) Confirm that the text input fields indicate the question number that the question belongs to. Radio buttons and checkboxes will be in fieldsets with a legend that indicates the question number when inspected. e.g. "Question x Select one:" or "Question x Select one or more:" for multiple choice questions and "Multiple choice x Question y" for multiple choice items in Cloze questions Questions with multiple select elements will have an accessible label with the format "Answer x Question y" Questions with text input answer fields will have an accessible label with the format "Answer Question x" The blank fields for drag and drop into text question types will have an accessible label with the format "Blank x Question y" The text area element for essay questions will have an accessible label with the format "Answer text Question x" The file picker element for essay questions will have an accessible label with the format "Answer files Question x" Confirm that for questions with customised question numbers, the question number shown on the answer fields' accessible label indicates the displayed customised question number. E.g. if a short answer question has a question number of "QS1", the accessible label of the answer field will be something like "Answer, question QS1" Answer the questions and press "Finish attempt..." Submit the quiz attempt and proceed to the next page (Review page) Check the accessible labels of the answer fields on the review page and confirm that the question number is indicated as well for the answer fields. Third-party plugins: Student quiz As a student, go to Student quiz 1. Start the quiz Go through each question and inspect the accessible label of the answer fields for each question. Note: You must rate each question before clicking on to the next question N Confirm that the question number is indicated on the accessible label of the answer fields. Third-party plugins: Embed questions filter Make sure you're using the Atto editor as your default editor. Create a Page resource. Name this as "Embedded questions page" On the Content field, expand the toolbar and click on the "Embed question" button (its icon looks like a checklist). On the "Embed question" modal, select " Default for QE [QE] (20) " On the question field, select any question (e.g. Cloze 2) then press "Embed question" Repeat the process to embed about two or more questions (e.g. a short answer, multichoice, etc.). Save and display the page. You might see debugging notices like " Invalid event functions defined in \filter_embedquestion\event\question_started ". Ignore this. Check the accessible label of the answer fields. Confirm that the question number is not indicated on the accessible label of the answer fields.

      This has been raised during the audit for the quiz attempt and review pages and is considered a Level A failure for Success Criterion 1.3.1 (Info and relationships).

      Notes from the audit:

      There are multiple input fields labelled "answer". This does not give the user any relevant information for inputting into the related input field.
      ...
      Recommend adding the question number to the label to output a result such as "answer, question six" and "answer, question seven", etc.

      This was raised for the following question types, especially when they're present on the same page:

      • Short answer
      • Numerical
      • Calculated
      • Calculated simple
      • Cloze

      For consistency, it may also be worth fixing this for the rest of the question types and indicating the question number for the answer field(s) for the questions.

        1. Screenshot 2023-01-24 at 11.09.21 am.png
          127 kB
          Jun Pataleta
        2. Screenshot 2023-01-24 at 11.11.17 am.png
          47 kB
          Jun Pataleta
        3. questionsinfieldset.png
          396 kB
          Jun Pataleta
        4. quiz_examples.mbz
          879 kB
          Jun Pataleta
        5. multianswer_before_after_BS_classes.png
          214 kB
          Jun Pataleta
        6. ddwtos_question_with_groups.xml
          3 kB
          Tim Hunt
        7. ddwtos-with-groups.png
          86 kB
          Jun Pataleta
        8. master_embed.png
          710 kB
          Ron Carl Alfon Yu
        9. 400_embed.png
          696 kB
          Ron Carl Alfon Yu
        10. 401_embed.png
          750 kB
          Ron Carl Alfon Yu
        11. 400_plugins.png
          1011 kB
          Ron Carl Alfon Yu
        12. 401_plugin.png
          1.06 MB
          Ron Carl Alfon Yu
        13. master_plugin.png
          1.06 MB
          Ron Carl Alfon Yu
        14. 400_quiz.png
          1.48 MB
          Ron Carl Alfon Yu
        15. 401_quiz.png
          1.65 MB
          Ron Carl Alfon Yu
        16. master_quiz.png
          1.69 MB
          Ron Carl Alfon Yu

            jpataleta Jun Pataleta
            jpataleta Jun Pataleta
            Tim Hunt Tim Hunt
            Andrew Lyons Andrew Lyons
            Ron Carl Alfon Yu Ron Carl Alfon Yu
            Votes:
            1 Vote for this issue
            Watchers:
            7 Start watching this issue

              Created:
              Updated:
              Resolved:

                Estimated:
                Original Estimate - Not Specified
                Not Specified
                Remaining:
                Remaining Estimate - 0 minutes
                0m
                Logged:
                Time Spent - 1 week, 1 day, 41 minutes
                1w 1d 41m

                  Error rendering 'clockify-timesheets-time-tracking-reports:timer-sidebar'. Please contact your Jira administrators.