手机号码正则,座机正则,400正则
var reg = /(^(0[0-9]{2,3}\-)?([2-9][0-9]{6,7})+(\-[0-9]{1,4})?$)|(^((\(\d{3}\))|(\d{3}\-))?(1[3578]\d{9})$)|(^(400)-(\d{3})-(\d{4})(.)(\d{1,4})$)|(^(400)-(\d{3})-(\d{4}$))/; if ( reg.test(gets) ){ alert('匹配成功'); }else{ alert('匹配失败'); }原文链接:https://www.f2er.com/jquery/422986.html