$string = iconv('utf-8' , 'gbk' , '2币1玩');
for($i = 0 ; $i < mb_strlen($string) ; $i ++){
$ords = '';
$attr = str_split($string[$i]);
for($j = 0 ; $j < count($attr) ; $j ++){
$ords .= decbin(ord($attr[$j]));
}
$bin_str = preg_replace('/^.{4}(.{4}).{2}(.{6}).{2}(.{6})$/','$1$2', $ords);
$result[] = dechex(bindec($bin_str));
}
var_dump($result);