We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 05414db commit 6fb321eCopy full SHA for 6fb321e
mf2/Parser.php
@@ -37,9 +37,7 @@ class Parser {
37
public function __construct($input, $baseurl = null, $htmlSafe = false) {
38
// For the moment: assume string = string of HTML
39
if (is_string($input)) {
40
- if (strtolower(mb_detect_encoding($input)) == 'utf-8') {
41
- $input = mb_convert_encoding($input, 'HTML-ENTITIES', "UTF-8");
42
- }
+ $input = mb_convert_encoding($input, 'HTML-ENTITIES', mb_detect_encoding($input));
43
44
$doc = new DOMDocument();
45
@$doc->loadHTML($input);
0 commit comments