diff --git a/app/helpers/utilityHelpers.php b/app/helpers/utilityHelpers.php index 6f4707bfd0..f6f1d3809e 100644 --- a/app/helpers/utilityHelpers.php +++ b/app/helpers/utilityHelpers.php @@ -5064,7 +5064,9 @@ function caQuoteRegexDelimiter(string $regex, string $delimiter) : string { * */ function caGetHTMLPurifier(?array $options=null) : HTMLPurifier { - $config = HTMLPurifier_Config::createDefault(); + #$config = HTMLPurifier_Config::createDefault(); + # Swapping out config with html5 compatiable config + $config = HTMLPurifier_HTML5Config::createDefault(); $config->set('URI.DisableExternalResources', !Configuration::load()->get('purify_allow_external_references')); $config->set('Cache.SerializerPath', Configuration::load()->get('purify_serializer_path')); return new HTMLPurifier($config); diff --git a/composer.json b/composer.json index b5616b8891..7f71e008c5 100755 --- a/composer.json +++ b/composer.json @@ -14,6 +14,7 @@ "easyrdf/easyrdf": "1.1.1", "elasticsearch/elasticsearch": "~7.0", "ezyang/htmlpurifier": "~4.9", + "xemlock/htmlpurifier-html5": "~0.1", "guzzlehttp/guzzle": "^7.9", "guzzlehttp/psr7": "2.7.*", "james-heinrich/getid3": "^1.9.20",