赞
踩
- function isValidIP(ip) {
- var reg = /^(\d{1,2}|1\d\d|2[0-4]\d|25[0-5])\.(\d{1,2}|1\d\d|2[0-4]\d|25[0-5])\.(\d{1,2}|1\d\d|2[0-4]\d|25[0-5])\.(\d{1,2}|1\d\d|2[0-4]\d|25[0-5])$/
- return reg.test(ip);
- }
-
- let a = isValidIP('10.10.10.1111')
- console.log(a)
Copyright © 2003-2013 www.wpsshop.cn 版权所有,并保留所有权利。