Fix for #14957 and probably a lot of other issues

Convert special characters for a valid use in xml documents
This commit is contained in:
Rüdiger Hahn 2020-10-09 10:59:06 +02:00 committed by GitHub
parent fe2e41527a
commit 5510f1feef
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -156,6 +156,7 @@ class Odf
*/
public function convertVarToOdf($value, $encode = true, $charset = 'ISO-8859')
{
$value = $encode ? htmlspecialchars($value) : $value;
$value = ($charset == 'ISO-8859') ? utf8_encode($value) : $value;
$convertedValue = $value;