From 6b533b45849042d2914ad973c0241f44f47eda07 Mon Sep 17 00:00:00 2001 From: dongsheng Date: Wed, 9 Apr 2008 06:07:06 +0000 Subject: [PATCH] MDL-14137, replace htmlentities with htmlspecialchars --- mod/data/lib.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/mod/data/lib.php b/mod/data/lib.php index f35970584eb65..5e3cbee5480a4 100755 --- a/mod/data/lib.php +++ b/mod/data/lib.php @@ -1812,7 +1812,7 @@ function data_presets_export($course, $cm, $data) { $presetxml .= "\n"; foreach ($settingssaved as $setting) { - $presetxml .= "<$setting>".htmlentities($data->$setting)."\n"; + $presetxml .= "<$setting>".htmlspecialchars($data->$setting, ENT_QUOTES)."\n"; } $presetxml .= "\n\n"; @@ -1822,7 +1822,7 @@ function data_presets_export($course, $cm, $data) { $presetxml .= "\n"; foreach ($field as $key => $value) { if ($value != '' && $key != 'id' && $key != 'dataid') { - $presetxml .= "<$key>".htmlentities($value)."\n"; + $presetxml .= "<$key>".htmlspecialchars($value, ENT_QUOTES)."\n"; } } $presetxml .= "\n\n";