php判断手机号码是否正确

function whether_is_telephone($telephone){
    if(preg_match("/^1[34578]{1}\d{9}$/", $telephone)){
        return true;
    }else{
        return false;
    }
}

  

posted @ 2024-03-19 20:31  侠岚歌  阅读(5)  评论(0)    收藏  举报