Convert gbk encoding to utf-8 after php curl
Issue
I use curl to get the website content, but the encoding of this page is gbk. Some characters are unreadable. The results are shown below.
Solution
With mb_convert_encoding method, we can convert character encoding. It need mbstring extension, add --enable-mbstring
when configure php. It Supports Character Encodings.
After convert encoding, the content is normal.