How to convert any possible format to UTF-8 using Iconv?

Posted by Ole Jak on Stack Overflow See other posts from Stack Overflow or by Ole Jak
Published on 2010-05-10T21:46:35Z Indexed on 2010/05/10 21:54 UTC
Read the original article Hit count: 241

Filed under:
|
|

so for example this will turn 1251 into utf-8.

$utf8 = iconv('windows-1251', 'utf-8', $ansi);

But how to turn unknown (when it comes to us we do not know yet what format it is) ( in general any ) format (possibly known by Iconv ) to utf-8?

© Stack Overflow or respective owner

Related posts about iconv

Related posts about php