i can't print the characters in encode. even i tried the ways ;
echo json_encode($user,JSON_UNESCAPED_UNICODE);
or iconv("ISO-8859-1", "UTF-8",$user)
Can you help me ? here codes;
$user = "ğığığı";
echo json_encode($user);
thanks for help.
i can't print the characters in encode. even i tried the ways ;
echo json_encode($user,JSON_UNESCAPED_UNICODE);
or iconv("ISO-8859-1", "UTF-8",$user)
Can you help me ? here codes;
$user = "ğığığı";
echo json_encode($user);
thanks for help.
You should use
echo json_encode($user,JSON_UNESCAPED_UNICODE|JSON_UNESCAPED_SLASHES);
You can see it work here http://sandbox.onlinephpfunctions.com/code/05d859c4b23417e54aad12fd96c8548949075c67