function chkallData(form) { if (form.userId.value == "") { alert("Please input user id!"); return; } if (form.userId.value.length < 4) { alert( "The User ID can not be less than 4 characters."); return; } if (form.password.value == "") { alert("Please input password!"); return; } if (form.password.value.length < 6) { alert("The Password can not be less than 6 characters."); return; } if (isIllegalString(form.userId.value)) { alert("The User ID contains illegal characters!"); return; } form.userId.value = form.userId.value.toUpperCase(); form.submit(); } function clrData(form) { form.userId.value = ""; form.password.value = ""; }