mb_detect_encoding($firstStr, array("ASCII","UTF-8","GB2312","GBK","BIG5"));
#判断字符编码
mb_substr
#获取字符长度
preg_match("/[\x7f-\xff]/",$firstStr)
# 判断中文
preg_match("/[a-zA-Z]/", $firstStr)
# 判断英文
mb_detect_encoding($firstStr, array("ASCII","UTF-8","GB2312","GBK","BIG5"));
#判断字符编码
mb_substr
#获取字符长度
preg_match("/[\x7f-\xff]/",$firstStr)
# 判断中文
preg_match("/[a-zA-Z]/", $firstStr)
# 判断英文