How to decode utf-8 in javascript?



Sorry if this may have been posted already, but i'm trying to get the original text of (ง︡'-'︠)ง but it still is parsing the xml file i have as (à¸ï¸¡'-'ï¸ )à :/


essentially what i want to do is parse the xml from another xml file, and it should end up like the first result, but unfortunately it's ending up like the second result :( anyway to fix this? i've tried the meta tag


<META http-equiv="Content-Type" content="text/html; charset=utf-8" />


I have made the same thing in php, and used the header which sets the charset to utf-8 and it works perfectly fine, now since i'm making it in javascript, it's giving me some issues :/


header('Content-Type: text/html; charset=utf-8');


So does anyone know how i can fix this?


cheers, and happy new year.


No comments:

Post a Comment