Moodle
  1. Moodle
  2. MDL-35517

When on the new course form I get a php warning

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Minor Minor
    • Resolution: Fixed
    • Affects Version/s: 2.4
    • Fix Version/s: 2.2.6, 2.3.3
    • Component/s: Course
    • Labels:
    • Testing Instructions:
      Hide

      0. Enable debugging display in the site with debug developer level.
      1. Log-in as admin.

      2. Go to Admin -> Courses -> Course default settings.
      3. Set "Maximum upload size" to any of the available values. Annotate it and also the list of available values.
      4. Save changes to the settings page.

      5. Go to Admin -> Courses -> Add/Edit Courses
      6. Click the "Add course" button. The course edit for will be shown.
      7. TEST: No PHP warning about "maxbytes" is shown/logged.
      8. TEST: The "Maximum upload size" popup setting shows the values and the default annotated in point 3.
      9. Change the "Maximum upload size" to another value. Annotate it.
      10. Complete the form (required fields) and save it. That will lead to the creation of a new course.

      11. Go to the course and edit its settings.
      12. TEST: No PHP warning about "maxbytes" is shown/logged.
      13. TEST: The "Maximum upload size" popup setting shows the values and the default annotated in point 9.

      That's all!

      Show
      0. Enable debugging display in the site with debug developer level. 1. Log-in as admin. 2. Go to Admin -> Courses -> Course default settings. 3. Set "Maximum upload size" to any of the available values. Annotate it and also the list of available values. 4. Save changes to the settings page. 5. Go to Admin -> Courses -> Add/Edit Courses 6. Click the "Add course" button. The course edit for will be shown. 7. TEST: No PHP warning about "maxbytes" is shown/logged. 8. TEST: The "Maximum upload size" popup setting shows the values and the default annotated in point 3. 9. Change the "Maximum upload size" to another value. Annotate it. 10. Complete the form (required fields) and save it. That will lead to the creation of a new course. 11. Go to the course and edit its settings. 12. TEST: No PHP warning about "maxbytes" is shown/logged. 13. TEST: The "Maximum upload size" popup setting shows the values and the default annotated in point 9. That's all!
    • Affected Branches:
      MOODLE_24_STABLE
    • Fixed Branches:
      MOODLE_22_STABLE, MOODLE_23_STABLE
    • Pull from Repository:
    • Pull Master Branch:
    • Rank:
      44228

      Description

      If I go to site admin > courses > add/edit courses then click on "add a new course" I get the following output.

      Notice: Undefined property: stdClass::$maxbytes in /home/andrew/Desktop/code/moodle/int/master/course/edit_form.php on line 159

        Issue Links

          Activity

          Hide
          Eloy Lafuente (stronk7) added a comment -

          Sending to integration. Trivial fix.

          Show
          Eloy Lafuente (stronk7) added a comment - Sending to integration. Trivial fix.
          Hide
          Dan Poltawski added a comment -

          The main moodle.git repository has just been updated with latest weekly modifications. You may wish to rebase your PULL branches to simplify history and avoid any possible merge conflicts. This would also make integrator's life easier next week.

          TIA and ciao

          Show
          Dan Poltawski added a comment - The main moodle.git repository has just been updated with latest weekly modifications. You may wish to rebase your PULL branches to simplify history and avoid any possible merge conflicts. This would also make integrator's life easier next week. TIA and ciao
          Hide
          Sam Hemelryk added a comment -

          Thanks Eloy, this has been integrated now

          Show
          Sam Hemelryk added a comment - Thanks Eloy, this has been integrated now
          Hide
          Michael de Raadt added a comment -

          Test results: Success!

          Show
          Michael de Raadt added a comment - Test results: Success!
          Hide
          Dan Poltawski added a comment -

          Congratulations, you've done it!

          Nf n erjneq sbe fhpprfshy vagrtengvba vagb guvf jrrxf eryrnfr, V pna abj qvfpybfr gb lbh gur rkvfgnapr bs shapgvba fge_ebg13(), gb tb va lbhe gbbyxvg nybat jvgu uggc://cuc.arg/znahny/ra/shapgvba.tmtrgff.cuc

          Cyrnfr qb abg nyybj guvf vasbezngvba gb cnff shegure.

          Show
          Dan Poltawski added a comment - Congratulations, you've done it! Nf n erjneq sbe fhpprfshy vagrtengvba vagb guvf jrrxf eryrnfr, V pna abj qvfpybfr gb lbh gur rkvfgnapr bs shapgvba fge_ebg13(), gb tb va lbhe gbbyxvg nybat jvgu uggc://cuc.arg/znahny/ra/shapgvba.tmtrgff.cuc Cyrnfr qb abg nyybj guvf vasbezngvba gb cnff shegure.

            People

            • Votes:
              1 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: