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

Images missing when restoring a course (V1.9) or a course / quiz (V2)

    Details

    • Testing Instructions:
      Hide

      Testing difficulty: easy

      1. In Moodle 1.9, create some questions with embedded images in the question bank of a course. To test all areas modified by this patch, you need to include
        • at least one image in question text of one question (any question type will do the job)
        • at least an image in the old "Image" filed that is now deprecated in Moodle 2.x
        • at least one image in general feedback of one question (any question type will do the job)
        • at least one image in the answer text of a multichoice question (Warning: there is no editor for that field in Moodle 1.9, the easiest way to include an image here is to include the image in another field with an editor like question's text, switch to HTML source and copy the HTML fragment related to the image to paste in answer's text field)
        • at least one image in each combined feedback field of a multichoice question (correct, partially correct and incorrect feedback)
        • at least one image in subquestion text of a matching question (use the same trick that for multichoice's answer text).
      2. Create a quiz that uses all the questions you created.
      3. Make a backup of this course including the quiz activity.
      4. You can also use the sample 1.9 backup attached to this issue.
      5. On 23, 24 and master branches
        1. Restore the backup
        2. TEST: Verify that all images are displayed in the questions and are not legacy files (i.e. they are served via pluginfile.php URL).
      Show
      Testing difficulty: easy In Moodle 1.9, create some questions with embedded images in the question bank of a course. To test all areas modified by this patch, you need to include at least one image in question text of one question (any question type will do the job) at least an image in the old "Image" filed that is now deprecated in Moodle 2.x at least one image in general feedback of one question (any question type will do the job) at least one image in the answer text of a multichoice question (Warning: there is no editor for that field in Moodle 1.9, the easiest way to include an image here is to include the image in another field with an editor like question's text, switch to HTML source and copy the HTML fragment related to the image to paste in answer's text field) at least one image in each combined feedback field of a multichoice question (correct, partially correct and incorrect feedback) at least one image in subquestion text of a matching question (use the same trick that for multichoice's answer text). Create a quiz that uses all the questions you created. Make a backup of this course including the quiz activity. You can also use the sample 1.9 backup attached to this issue. On 23, 24 and master branches Restore the backup TEST: Verify that all images are displayed in the questions and are not legacy files (i.e. they are served via pluginfile.php URL).
    • Affected Branches:
      MOODLE_22_STABLE, MOODLE_24_STABLE
    • Fixed Branches:
      MOODLE_23_STABLE, MOODLE_24_STABLE
    • Pull Master Branch:

      Description

      Images attached to questions (quiz) lost when restoring a course from platform V1.9 or Course/quiz from V2.1 or V2.2 platforms
      Moodle 2.2.2 + (Build: 20120419).

        Gliffy Diagrams

          Attachments

            Issue Links

              Activity

                People

                • Votes:
                  13 Vote for this issue
                  Watchers:
                  20 Start watching this issue

                  Dates

                  • Created:
                    Updated:
                    Resolved:
                    Fix Release Date:
                    18/Mar/13