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

Changing language while managing backup files causes returnurl to be stripped

XMLWordPrintable

    • MOODLE_404_STABLE, MOODLE_405_STABLE

      When you switch your selected language while in the manage backup files page within a course and click on either the save or cancel button, you are redirected to $CFG->wwwroot/backup/

      The reason for this is that the hidden returnurl value in the form is being stripped on language change and so when the form is posted the redirect fails.

      Steps to produce:

      1. Create a new course and enter it
      2. In the course management tabs, Select More -> Reuse and then choose backup from the resultant page
      3. Click jump to end to complete the backup
      4. Click continue to get to the Restore page
      5. Click on the Manage course backups button
      6. when presented with the course backup files change your language in the Profile dropdown menu -> languages option
      7. Clicking either Cancel or save will bring you to the wrong place.

      If you inspect the hidden form elements it looks like the first screenshot and after the language change it then looks like the second one.

      It should have the backup/restrorefile.php with the contextid being passed as a parameter.

       

            Unassigned Unassigned
            derick-eld Derick Turner
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:

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