3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $cp1252 = "\x61\x61\x61\xE7\x62\x62\x62"; // aaaçbbb in Windows-1252 $utf8 = mb_convert_encoding($cp1252, "UTF-8", "Windows-1252"); echo "Hex (1252): ".bin2hex($cp1252)."\n"; echo "Hex (UTF8): ".bin2hex($utf8)."\n"; echo "Plain UTF8: ".$utf8."\n";
Output for 4.3.0 - 5.6.28, hhvm-3.10.0 - 3.12.0, 7.0.0 - 7.1.0
Hex (1252): 616161e7626262 Hex (UTF8): 616161c3a7626262 Plain UTF8: aaaçbbb