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

unpropitious use of bcmod()

    XMLWordPrintable

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 2.0.3, 2.1
    • Fix Version/s: 2.0.4
    • Component/s: Feedback
    • Labels:
      None
    • Environment:
      php compiled without php5-bcmath
    • Testing Instructions:
      Hide

      create two questions in any feedback. One multichoice and one multichoicerated.
      do some submitts.
      Go to the analysis-page.
      If bcmod() is available so the printed bars are in different colours.
      If bcmod() isn't available so the printed bars are all the same colour.

      Show
      create two questions in any feedback. One multichoice and one multichoicerated. do some submitts. Go to the analysis-page. If bcmod() is available so the printed bars are in different colours. If bcmod() isn't available so the printed bars are all the same colour.
    • Affected Branches:
      MOODLE_20_STABLE, MOODLE_21_STABLE
    • Fixed Branches:
      MOODLE_20_STABLE
    • Pull from Repository:
    • Pull Master Branch:
      MDL-28014_head

      Description

      There are two calls of bcmod() in item/multichoice/lib.php and item/multichoicerated/lib.php but this function isn't available on each installation.
      Better is to use the % for modulus then bcmod().
      This was just used in a very early time I started php programming .

        Attachments

          Activity

            People

            Assignee:
            grabs Andreas Grabs
            Reporter:
            grabs Andreas Grabs
            Integrator:
            Sam Hemelryk
            Tester:
            Rajesh Taneja
            Participants:
            Component watchers:
            Amaia Anabitarte, Carlos Escobedo, Ferran Recio, Sara Arjona (@sarjona), Víctor Déniz Falcón
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:
              Fix Release Date:
              1/Aug/11