diff --git a/CHANGELOG.md b/CHANGELOG.md index d02df5d..5f88ca4 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,8 @@ All notable changes to this project will be documented in this file. ### Updated - Partial fix for sizing issue of radial and pie charts in Moodle 4.1 and 4.2. - Copyright notice to include 2023. +- Compatibility with Moodle 4.2. +- Compatibility with PHP 8.1. ## [2.3.4] 2022-12-11 ### Added diff --git a/filter.php b/filter.php index 663aed5..05b78f7 100644 --- a/filter.php +++ b/filter.php @@ -350,16 +350,16 @@ private function scrapehtml($url, $tag = '', $class = '', $id = '', $code = '') if (empty($tag)) { $tag .= '*'; // Match any tag. } - $query = "//${tag}"; + $query = "//{$tag}"; // If a class was specified. if (!empty($class)) { - $query .= "[@class=\"${class}\"]"; + $query .= "[@class=\"{$class}\"]"; } // If an id was specified. if (!empty($id)) { - $query .= "[@id=\"${id}\"]"; + $query .= "[@id=\"{$id}\"]"; } $tag = $xpath->query($query); diff --git a/lang/en/filter_filtercodes.php b/lang/en/filter_filtercodes.php index 583bbe1..952ca7c 100644 --- a/lang/en/filter_filtercodes.php +++ b/lang/en/filter_filtercodes.php @@ -73,7 +73,7 @@ $string['teamcardslinktype'] = 'Team link type'; $string['teamcardslinktype_desc'] = 'Choose the type of link for the team member\'s link in the {teamcards} tag. Note: Photo will automatically be linked to profile when the user is logged-in regardless of your choice here.'; $string['narrowpage'] = 'Narrow page'; -$string['narrowpage_desc'] = 'Enable this option to optimize display of information if Moodle is using a theme with limited page width (e.g., Boost in Moodle 4.0).'; +$string['narrowpage_desc'] = 'Enable this option to optimize display of information if Moodle is using a theme with limited page width (e.g., Boost in Moodle 4.0+).'; $string['sizeb'] = 'B'; $string['sizekb'] = 'KB'; $string['sizemb'] = 'MB'; diff --git a/version.php b/version.php index 9db7204..b89380f 100644 --- a/version.php +++ b/version.php @@ -25,8 +25,8 @@ defined('MOODLE_INTERNAL') || die(); -$plugin->version = 2022121102; // The current plugin version (Date: YYYYMMDDXX). +$plugin->version = 2023050700; // The current plugin version (Date: YYYYMMDDXX). $plugin->requires = 2014051200; // Requires Moodle version 2.7 or later. $plugin->component = 'filter_filtercodes'; // Full name of the plugin (used for diagnostics). -$plugin->release = '2.3.5'; +$plugin->release = '2.3.6'; $plugin->maturity = MATURITY_STABLE;