/** * 字符串转数组 * @param type $str * @return type */ public static function ch2arr($str) { $length = mb_strlen($str, 'utf-8'); $array = []; for ($i = 0; $i < $length; $i++) $array[] = mb_substr($str, $i, 1, 'utf-8'); return $array; }
关键字词: