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

Import of Blackboard 5 questions error due to php5 variable handling (replace $q = $defaultq with $q = clone $defaultq)

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Minor Minor
    • 1.6.4, 1.7, 1.8
    • 1.6.3
    • Questions
    • None
    • php5 - this is soon going to be the default php environment for new servers, isn't it?
    • MOODLE_16_STABLE
    • MOODLE_16_STABLE, MOODLE_17_STABLE, MOODLE_18_STABLE

      PHP5 seems to treat variable assignment in a fundamentally different way when copying a variable. ex.: $question = $defaultq in questions/format/blackboard/format.php
      $defaultq is passed in as a parameter to several functions in format.php

      the solution seems to be making a slight adjustment to the line intended to make a copy of the default question passed in.
      $question = clone $defaultq; // fixed in several places

            timhunt Tim Hunt
            atmanning Arthur Manning (Inactive)
            Nobody Nobody (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:

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