-
Notifications
You must be signed in to change notification settings - Fork 50
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
Fix utf-8 encoding problem #19
base: master
Are you sure you want to change the base?
Conversation
Replace `_root` by constant `self::FRAGMENT_ROOT_TAGNAME`
Try to fix utf-8 encoding problem.
Don't output DocType if only `saveHTML` of elements.
I think we should keep the newline and whitespace.
I've ran into the same issue myself now, and this fix would be highly apprectiated. @wasinger Is it possible to get this merged? |
I finally gave up this project and wrote my own html dom parse. But I am new on starting up a open source project. |
I think it can help you. curl_setopt($ch, CURLOPT_ENCODING, 'UTF-8'); |
@kukungkung setting curlopt is just try to request with encoding |
the problem is not that utf8 is not parsed, just that result is encoded with html entities. i solved this in my code: $html = html_entity_decode((string)$crawler, ENT_NOQUOTES, 'UTF-8'); |
Due to the urgent need in my project, hope it can help. #18