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

Binary or non UTF-8 characters mistake. (relation to the characters used in this document and the special characters) #35

Open
oaztech opened this issue Feb 25, 2021 · 0 comments

Comments

@oaztech
Copy link

oaztech commented Feb 25, 2021

When I'm trying to minify my HTML newsletter document, some newsletters doesn't convert normally to string, and this make a mistake when i trying to convert minify result to string by casting, the picture below show two documents after minifying the first is recognized as binary or non utf-8 character, and the second recognized as normal string. This has a relation to the characters used in this document and the special characters.
Capture d’écran 2021-02-25 155150

This problem makes a mistake when i am using the result of minifying in a library and this last try to convert the result to string to build a JSON object.
Screenshot (202)

To solve this problem, I use mb_convert_encoding function of PHP to convert the result to utf-8 standard.

mb_convert_encoding( $string, "UTF-8");
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant