3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $t = "Текст"; $t = mb_convert_encoding($t, 'cp1251', 'utf-8'); $t = htmlspecialchars($t); echo $t;
Output for 5.4.0 - 5.6.28, hhvm-3.10.0 - 3.12.0, 7.0.0 - 7.1.0
Output for 4.3.4 - 5.3.29
�����
Output for 4.3.2 - 4.3.3
Warning: mb_convert_encoding(): Unknown encoding "cp1251" in /in/Cj2Nl on line 5
Output for 4.3.0 - 4.3.1
Warning: mb_convert_encoding() [http://www.php.net/function.mb-convert-encoding]: Unknown encoding "cp1251" in /in/Cj2Nl on line 5