JavaScript中判断字符串中是否含有中文字符
function funcChina(str){
if(/.*[\u4e00-\u9fa5]+.*$/.test(str))
{
return false;
//不是中文
}
return true;
}
function funcChina(str){
if(/.*[\u4e00-\u9fa5]+.*$/.test(str))
{
return false;
//不是中文
}
return true;
}