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

update weblib.php for PHP 5.4

    XMLWordPrintable

Details

    • Improvement
    • Resolution: Deferred
    • Minor
    • None
    • 2.7, 2.7.3, 2.8.1, 2.9
    • Libraries

    Description

      I was doing some light reading the other day and found the following comment in lib/weblib.php

          // When we move to PHP 5.4 as a minimum version, change ENT_QUOTES on the
          // next line to ENT_QUOTES | ENT_HTML5 | ENT_SUBSTITUTE, and remove the
          // 'UTF-8' argument. Both bring a speed-increase.
          return preg_replace('/&#(\d+|x[0-9a-f]+);/i', '&#$1;', htmlspecialchars($var, ENT_QUOTES, 'UTF-8'));

      As of Moodle 2.7 PHP 5.4 is required so this change should be made to 2.7 and 2.8dev. I don't know what it means, but hope somebody remembers it.

      See https://github.com/moodle/moodle/blob/master/lib/weblib.php#L99

      Attachments

        Issue Links

          Activity

            People

              cameron1729 cameron1729
              dthies Daniel Thies
              Votes:
              2 Vote for this issue
              Watchers:
              8 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Clockify

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