正则拓展: 匹配大陆和港式身份证直入主题效果图
直入主题产品有香港的小伙伴入驻..身份证校验这块需要做一个前台校验,尝试了许久…就放出来了两种写法:(\d{6})(\d{4})(\d{2})(\d{2})(\d{3})([0-9]|X)|[A-Za-z]{1}\d{6}[(\d)]{3}([A-Za-z](\d{6})\(\d\))|(\d{6})(\d{4})(\d{2})(\d{2})(\d{3})([0-9]|X|x)效果图