1if (typeof waitForJQAndRun === "function") { 2 waitForJQAndRun(regFormScriptInitJQ, false, 100); 3} 4 5function regFormScriptInitJQ() { 6 $("form.cmsform input[name=\"password\"]").on("change keyup", function () { 7 checkPassChange(this); 8 }); 9 $("form.cmsform input[name=\"password2\"]").on("change keyup", function () { 10 checkPass2Change(this); 11 }); 12} 13 14function checkPass2Change(element) { 15 var pass2input = $(element ? element : "input[name=\"password2\"]"); 16 if (pass2input.length === 0) { 17 return; 18 } 19 if (pass2input.val() == $("input[name=\"password\"]").val()) { 20 hideFormFieldMsg("form.cmsform", "password2"); 21 setInputDynamicValid(pass2input); 22 } else { 23 showFormFieldMsg("form.cmsform", "password2", "Passwords don't match"); 24 setInputDynamicInvalid(pass2input); 25 } 26} 27 28function checkPassChange(element) { 29 if (element.value == "" 30 || (element.value.match(/[a-z]/) && element.value.match(/[A-Z]/) && element.value.match(/[0-9]/) && element.value.length > 9) 31 ) { 32 hideFormFieldMsg("form.cmsform", "password"); 33 setInputDynamicValid(element); 34 } else { 35 showFormFieldMsg("form.cmsform", "password", "Password must contain at least 1 upper case letter, 1 lower case letter, and 1 digit. The minimum allowed length is 10 characters."); 36 setInputDynamicInvalid(element); 37 38 } 39 checkPass2Change(); 40}
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.