添加检查密码范围支持的特殊字符包括:~!@#$%^&*()-=_+
This commit is contained in:
@ -366,7 +366,7 @@ function checkpwd(chrtype, password) {
|
||||
}
|
||||
} else if (chrtype == 4) {
|
||||
if(!$.common.charValid(password)){
|
||||
$.modal.alertWarning("密码必须包含字母、数字、以及特殊符号-、_");
|
||||
$.modal.alertWarning("密码必须包含字母、数字、以及特殊符号<font color='red'>~!@#$%^&*()-=_+</font>");
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
@ -1637,7 +1637,7 @@ var table = {
|
||||
},
|
||||
// 英文、数字、特殊字符正则表达式,必须包含(字母,数字,特殊字符-_)
|
||||
charValid : function(text){
|
||||
var patten = new RegExp(/^(?=.*[A-Za-z])(?=.*\d)(?=.*[-_])[A-Za-z\d-_]{6,}$/);
|
||||
var patten = new RegExp(/^(?=.*[A-Za-z])(?=.*\d)(?=.*[~!@#\$%\^&\*\(\)\-=_\+])[A-Za-z\d~!@#\$%\^&\*\(\)\-=_\+]{6,}$/);
|
||||
return patten.test(text);
|
||||
},
|
||||
}
|
||||
|
Reference in New Issue
Block a user