From e0d0f411cf1b263f89021fef3287c6a200f8b40a Mon Sep 17 00:00:00 2001 From: Zig Tan Date: Fri, 15 Dec 2017 09:19:26 +0800 Subject: [PATCH] MDL-54967 backup: Fix IMS CC import URL decoding for XML format HTML encoding special characters to avoid XML compatibility issues during Course backup restoration and avoid double encoding. --- backup/cc/entity11.resource.class.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/backup/cc/entity11.resource.class.php b/backup/cc/entity11.resource.class.php index bc5bb5aab07..7bb6da78d02 100644 --- a/backup/cc/entity11.resource.class.php +++ b/backup/cc/entity11.resource.class.php @@ -99,7 +99,7 @@ class cc11_resource extends entities11 { $link = 'http://invalidurldetected/'; } } else { - $link = $rawlink; + $link = htmlspecialchars(trim($rawlink), ENT_COMPAT, 'UTF-8', false); } } }