I'm implementing facebook login on my site and the auth process works fine, but there is another problem. When I try to get the name of the user from the auth response, I'm getting this:
Array ( [name] => Ðиколай ДÑнков [image] => ...
This name is supposed to be in Cyrillic characters and I need to:
I tried using json_decode() and iconv() but no success. Maybe I can't get the parameters right. Please help!
Use header to modify the HTTP header:
header('Content-Type: text/html; charset=utf-8');
Place it at the top of your php file or at a common file which you include everywhere, such as config file.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.