3
$.validator.addMethod("validpassword", function(value, element) {
return this.optional(element) ||
/^.*(?=.{8,})(?=.*[a-z])(?=.*[A-Z])(?=.*[\d])(?=.*[\W]).*$/i.test(value);
}, "The password must contain a minimum of one lower case character," +
" one upper case character, one digit and one special character..");
上述正则表达式不大写和小写之间进行区分。怎么了?jQuery验证密码强度的大写和小写
感谢您提供“我”,以便从模式中撤销不区分大小写。 – 2017-06-19 11:45:48