Browse Source

密码过短过长提示

visuddhinanda@gmail.com 4 năm trước cách đây
mục cha
commit
e96bad5807
1 tập tin đã thay đổi với 8 bổ sung1 xóa
  1. 8 1
      public/app/ucenter/sign.js

+ 8 - 1
public/app/ucenter/sign.js

@@ -24,7 +24,14 @@ function submit(){
 		$("#error_password").text(gLocal.gui.password_invaild_symbol);
 		hasError = true;
 	}
-
+	if($("#password").val().length < 6){
+		$("#error_password").text('Password is too short');
+		hasError = true;
+	}
+    if($("#password").val().length > 31){
+		$("#error_password").text('Password is too long');
+		hasError = true;
+	}
 	if(isValidUserName($("#username").val())==false){
 		$("#error_username").text(gLocal.gui.username_invaild_symbol);
 		hasError = true;