ID: 47876 User updated by: FrancS at seznam dot cz Reported By: FrancS at seznam dot cz Status: Open Bug Type: mbstring related Operating System: Windows XP PHP Version: 5.2.9 New Comment:
I look again on it and problem is with "á" in word with no other accent chars in it. Previous Comments: ------------------------------------------------------------------------ [2009-04-02 10:08:07] FrancS at seznam dot cz Description: ------------ Hi, today I discover a problem with mb function mb_detect_encoding(). I have a string "chráany" in czech language. It seems that this function everytime return UTF-8 encoding, even if I load the text from a file with encoding "windows-1250" or "ISO-8859-2". Reproduce code: --------------- // test.txt is text file with charset "windows-1250" or "ISO-8859-2" $string = file_get_contents('test.txt'); var_dump(mb_detect_encoding($string, mb_list_encodings(), true)); Expected result: ---------------- SJIS Actual result: -------------- utf-8 ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=47876&edit=1