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

Viewing course files throwing exception

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Major Major
    • None
    • 2.0
    • Files API
    • None
    • MOODLE_20_STABLE

      I was working with Mary Cooch and originally thought this might be related to having installed the Flickr repository since after enabling the Flickr plugin and going to browse a course's files (including site files) I receive:

      Coding error detected, it must be fixed by a programmer: Url parameters can not have numeric keys!

      Coding error detected, it must be fixed by a programmer: Unrecognied URL scheme. Please check the formatting of the URL passed to this function. Absolute URLs are the preferred scheme.

      I did a var_dump($params) which yielded:

      array(5)

      { [0]=> string(12) "contextid=14" [1]=> string(23) "filearea=course_content" [2]=> string(8) "itemid=0" [3]=> string(12) "filepath=%2F" [4]=> string(9) "filename=" }

      var_dump($key) produces:

      int(0)

      I am not sure if it is in the call to moodle_url in /files/index.php around line 49:

      redirect(new moodle_url('index.php', array('contextid' => $context->id, 'itemid'=> 0, 'filearea' => 'course_content')));

      I am not sure what is happening but something is getting passed incorrectly such that $params is seeing the index as an int.

      Peace - Anthony

            skodak Petr Skoda
            aborrow Anthony Borrow
            Nobody Nobody (Inactive)
            Votes:
            1 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved:

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