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

backup should honor $CFG->formatstringstriptags (setting_invalid_ui_label exception)

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Minor Minor
    • 3.10.8, 3.11.4
    • 3.9.6, 3.10.3, 3.11, 4.0
    • Backup
    • MOODLE_310_STABLE, MOODLE_311_STABLE, MOODLE_39_STABLE, MOODLE_400_STABLE
    • MOODLE_310_STABLE, MOODLE_311_STABLE
    • 71093-master-backup-honor-formatstringstriptags
    • Hide

      setup requirements (tests without HTML tags)

      1. create a course with topics format
      2. edit one of the sections of the course and enter custom name without HTML tags (eg : test) for the title
      test 1
      1. add $CFG->formatstringstriptags = false; in config.php
      2. go to course backup page
      3. check there is no error on first course backup page
      test 2
      1. add $CFG->formatstringstriptags = true; in config.php
      2. go to course backup page
      3. check there is no error on first course backup page

      setup requirements (tests with HTML tags)

      1. create a course with topics format
      2. edit one of the sections of the course and enter custom name with HTML tags (eg : <b>test</b>) for the title (do not use quick edit, see MDL-65934)
      test 1
      1. add $CFG->formatstringstriptags = false; in config.php
      2. go to course backup page
      3. check there is no error on first course backup page
      test 2
      1. add $CFG->formatstringstriptags = true; in config.php
      2. go to course backup page
      3. check there is no error on first course backup page
      Show
      setup requirements (tests without HTML tags) create a course with topics format edit one of the sections of the course and enter custom name without HTML tags (eg : test ) for the title test 1 add $CFG->formatstringstriptags = false; in config.php go to course backup page check there is no error on first course backup page test 2 add $CFG->formatstringstriptags = true; in config.php go to course backup page check there is no error on first course backup page setup requirements (tests with HTML tags) create a course with topics format edit one of the sections of the course and enter custom name with HTML tags (eg : <b>test</b> ) for the title (do not use quick edit, see MDL-65934 ) test 1 add $CFG->formatstringstriptags = false; in config.php go to course backup page check there is no error on first course backup page test 2 add $CFG->formatstringstriptags = true; in config.php go to course backup page check there is no error on first course backup page

      When you allow HTML tags in activity and resource names ($CFG->formatstringstriptags) and you have HTML tags in section name, you can't backup your course.

      Steps to Reproduce

      1. add $CFG->formatstringstriptags = false; to your config.php
      2. create a course with topics format
      3. edit one of the sections of the course and enter custom name for the title with some HTML tags (do not use quick edit, see MDL-65934)
      4. then try to backup your course. You should have an exception error "error/setting_invalid_ui_label"

       

            jboulen Julien Boulen
            jboulen Julien Boulen
            Sujith Haridasan Sujith Haridasan
            Eloy Lafuente (stronk7) Eloy Lafuente (stronk7)
            Angelia Dela Cruz Angelia Dela Cruz
            Votes:
            1 Vote for this issue
            Watchers:
            12 Start watching this issue

              Created:
              Updated:
              Resolved:

                Estimated:
                Original Estimate - 0 minutes
                0m
                Remaining:
                Remaining Estimate - 0 minutes
                0m
                Logged:
                Time Spent - 3 hours, 25 minutes
                3h 25m

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