var reg=/^((1\d\d|2[0-4]\d|25[0-5]|\d{1,2})\.){3}(1\d\d|2[0-4]\d|25[0-5]|\d{1,2})$/
1\d\d 匹配(100-199)
2[0-4]\d 匹配(200-249)25[0-5] 匹配(250-255)\d{1,2} 匹配(0-99)(1\d\d|2[0-4]\d|25[0-5]|\d{1,2}).){3} (0-255.)匹配三次(1\d\d|2[0-4]\d|25[0-5]|\d{1,2}) (0-255)结尾匹配一次