function forgotPasswd() { showDialog("( ̄﹏ ̄;)", "欸这个嘛...我还没做完呢...( ̄﹏ ̄;)"); } function closeDialog() { $("#dialogMask").fadeOut(400); } function checkInputDataCorrect(username, password) { if (username == "" || passwd == "") { showMessage("用户名和密码都不可以是空的哦"); return false; } if (!isLetter(username)) { showMessage("用户名只能是大小写字母和数字哦"); return false; } if (!isNormalCharacter(passwd)) { showMessage("不知道你往密码框都搞了点什么东西..."); return false; } return true; } function showMessage(message) { $("#errMsgBox")[0].innerHTML = `

${message}

`; } function clearMessage() { $("#errMsgBox")[0].innerHTML = ``; } function showDialog(title, message) { html = `

${title}


${message}

`; dialogMask = $("#dialogMask"); dialogMask[0].innerHTML = html; $(".dialogContentBox .bottonBox #okbtn").click(closeDialog); dialogMask.fadeIn(400); dialogMask.css("display", "block"); }