Skip to content

Commit

Permalink
Internal: Revert PHP 8 compatibility improvement in api_htmlentities(…
Browse files Browse the repository at this point in the history
…) as it causes issues filtering HTML tags in HTML titles - refs BT#22321
  • Loading branch information
ywarnier committed Dec 24, 2024
1 parent 31e06df commit 8c16c19
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion main/inc/lib/internationalization.lib.php
Original file line number Diff line number Diff line change
Expand Up @@ -1207,7 +1207,7 @@ function api_htmlentities($string, $quote_style = ENT_COMPAT, $encoding = 'UTF-8
break;
}

return htmlspecialchars($string);
return mb_convert_encoding($string, 'HTML-ENTITIES', 'UTF-8');
}

/**
Expand Down

0 comments on commit 8c16c19

Please sign in to comment.