Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Malformed charset in a message with invalid HTML structure #7116

Closed
alecpl opened this issue Dec 16, 2019 · 1 comment
Closed

Malformed charset in a message with invalid HTML structure #7116

alecpl opened this issue Dec 16, 2019 · 1 comment

Comments

@alecpl
Copy link
Member

alecpl commented Dec 16, 2019

Sample HTML code

<html>
<head>
   <title></title>
</head>
<body> Content here with unicode characters</body>
<meta charset=utf-8>
</html>

So, the meta tag is not in head, which is a problem for DOMDocument and our code that workarounds missing charset definition. Not a problem for Masterminds/HTML5 parser.

I think we could improve our workaround code, so it removes the meta tag and adds it into head.

@alecpl
Copy link
Member Author

alecpl commented Dec 16, 2019

Fixed.

@alecpl alecpl closed this as completed Dec 16, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant