3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php function removeBOM($str="") { if(substr($str, 0, 3) == pack("CCC", 0xef, 0xbb, 0xbf)) { $str = substr($str, 3); } return $str; }
based on FT3XC
Output for 4.3.0 - 7.1.0