diff options
| author | Simon Rettberg | 2025-07-01 10:32:09 +0200 |
|---|---|---|
| committer | Simon Rettberg | 2025-07-01 10:32:09 +0200 |
| commit | 565d30685fe75916e953de425fe71ec1670c88fb (patch) | |
| tree | d02a82a3906fd2fd98829df5be5abf69d4d4bd20 | |
| parent | [serversetup-bwlp-ipxe] Remove unused function (diff) | |
| download | slx-admin-565d30685fe75916e953de425fe71ec1670c88fb.tar.gz slx-admin-565d30685fe75916e953de425fe71ec1670c88fb.tar.xz slx-admin-565d30685fe75916e953de425fe71ec1670c88fb.zip | |
[locationinfo] icalparser: Undo the entity encoding before returning iCal data
| -rw-r--r-- | modules-available/locationinfo/inc/icalparser.inc.php | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/modules-available/locationinfo/inc/icalparser.inc.php b/modules-available/locationinfo/inc/icalparser.inc.php index 54869c2e..5b75de5f 100644 --- a/modules-available/locationinfo/inc/icalparser.inc.php +++ b/modules-available/locationinfo/inc/icalparser.inc.php @@ -988,11 +988,23 @@ class ICalParser $matches[1] = $properties; } + $this->entity_decode_recursive($matches); return $matches; } return null; // Ignore this match } + private function entity_decode_recursive(&$matches): void + { + if (is_string($matches)) { + $matches = html_entity_decode($matches, ENT_QUOTES, 'UTF-8'); + } elseif (is_array($matches)) { + foreach ($matches as &$match) { + $this->entity_decode_recursive($match); + } + } + } + /** * Returns a `DateTime` object from an iCal date time format * |
