Detect character encodings
Posted: Thu Dec 18, 2008 3:10 am
Hi guys,
I got a lot of txt files, and I need to detect encoding of them. I need to call some function, which will tell me encoding of input string and it will return name of encoding, for example UTF8, ISO-8859-1, ISO-8859-2...
I tried http://sk.php.net/manual/en/function.mb ... coding.php but it doesnt work properly. mb_detect_encoding('skúška'); returns UTF-8, what is wrong.
Anybody ?
Thank you.
I got a lot of txt files, and I need to detect encoding of them. I need to call some function, which will tell me encoding of input string and it will return name of encoding, for example UTF8, ISO-8859-1, ISO-8859-2...
I tried http://sk.php.net/manual/en/function.mb ... coding.php but it doesnt work properly. mb_detect_encoding('skúška'); returns UTF-8, what is wrong.
Anybody ?
Thank you.