varAuth_email = 0, auth_pwd = 0, Auth_captcha = 0, Url_ajax = "/protected/user_ajax.php";functionCheckmail () {varA =/^ ([a-za-z0-9]+[_|\_|\.]?) *[a-za-z0-9][email protected] ([a-za-z0-9]+[_|\_|\.]?) *[a-za-z0-9]+\. [A-za-z] {2,3}$/, _ = $ ("#input-email"). Val (). toLocaleLowerCase (); if(!A.test (_)) { if($ (". Form-group-email"). Find ("small"). Text () = = "") $(". Form-group-email"). Find ("small"). Text ("\u90ae\u7bb1\u683c\u5f0f\u4e0d\u6b63\u786e")); return false } Else$.ajax ({url:url_ajax, cache:false, type:"POST", Async:false, data: {email: _, Operate:"Isexist_email"}, Success:function (_) { if(_ = = "Avaliable") { $(". Form-reg. Form-group-email"). Find ("small"). Text (""); Auth_email= 1 } Else if(_ = = "Isexist") { $(". Form-group-email"). Find ("small"). Text ("\u6b64\u90ae\u7bb1\u5df2\u88ab\u6ce8\u518c")); Auth_email= 0}}, Error:function() {alert ("\u53d1\u751f\u5f02\u5e38") } })}functionCheckMail2 () {varA =/^ ([a-za-z0-9]+[_|\_|\.]?) *[a-za-z0-9][email protected] ([a-za-z0-9]+[_|\_|\.]?) *[a-za-z0-9]+\. [A-za-z] {2,3}$/, _ = $ ("#input-email"). Val (). toLocaleLowerCase (); $(". Form-reg div"). EQ (0). FIND ("span"). Remove (); if(!A.test (_)) { if($ (". Form-group-email"). Find ("small"). Text () = = "") { $(". Form-group-email"). Find ("small"). Text ("\u90ae\u7bb1\u683c\u5f0f\u4e0d\u6b63\u786e")); Auth_email= 0 } } Else{Auth_email= 1; $(". Form-reg. Form-group-email"). Find ("small"). Text ("") }}functioncheckpwd () {varA =/^ (?! [a-z]+$) (?! \d+$) [a-z0-9_]{8,16}$/I, _= $ ("#input-pwd"). Val (); if(_.length < 8) { if($ (". Form-group-pwd"). Find ("small"). Text () = = "") { $(". Form-group-pwd"). Find ("small"). Text ("\U5BC6\U7801\U957F\U5EA6\U4E0D\U8DB38\U4F4D")); Auth_pwd= 0 } return false } if(!A.test (_)) { $(". Form-group-pwd"). Find ("small"). Text ("\u5bc6\u7801\u4ec5\u5305\u542b\u5b57\u6bcd\u4e0e\u6570\u5b57")); Auth_pwd= 0; return false } $(". Form-reg. Form-group-pwd"). Find ("small"). Text (""); Auth_pwd= 1}functioncheckPwd2 () {varA =/^ (?! [a-z]+$) (?! \d+$) [a-z0-9_]{8,16}$/I, _= $ ("#input-pwd"). Val (); if(_.length < 8) { if($ (". Form-group-pwd"). Find ("small"). Text () = = "") { $(". Form-group-pwd"). Find ("small"). Text ("\U5BC6\U7801\U957F\U5EA6\U4E0D\U8DB38\U4F4D")); Auth_pwd= 0 } return false } if(!A.test (_)) { $(". Form-group-pwd"). Find ("small"). Text ("\u5bc6\u7801\u4ec5\u5305\u542b\u5b57\u6bcd\u4e0e\u6570\u5b57")); Auth_pwd= 0; return false } $(". Form-reg. Form-group-pwd"). Find ("small"). Text (""); Auth_pwd= 1}functionCheckcaptcha () {var_ = $ ("#input-captcha"). Val (). toLocaleLowerCase (); $.ajax ({url:url_ajax, type:"POST", Async:false, data: {captcha: _, Operate:"Check_captcha"}, Success:function (_) { if(_ = = "Pass") { $(". Form-reg. Captcha"). Find ("small"). Text (""); Auth_captcha= 1 } Else if(_ = = "NoPass") { $(". Form-reg. Captcha"). Find ("small"). Text ("\u9a8c\u8bc1\u7801\u4e0d\u6b63\u786e"); Auth_captcha= 0}}, Error:function() {alert ("\u53d1\u751f\u5f02\u5e38") } })}functionChangecaptcha () {$ (". Img-captcha"). Click ()}functionChecksubmit () {$ (". Btn-reg"). attr ("Disabled",true). attr ("value", "\u9a8c\u8bc1\u4e2d..")); Checkcaptcha (); Checkmail (); Checkpwd (); if(Auth_email = = 1 && auth_pwd = = 1 && auth_captcha = 1) { $(". Btn-reg"). attr ("Disabled",true). attr ("value", "\u6ce8\u518c\u4e2d..")); $(". Form-reg"). Submit ()}Else { $(". Btn-reg"). attr ("Disabled",false). attr ("value", "\u6ce8\u518c"); return false }}functionCheckSubmit2 () {$ (". Btn-login"). attr ("Disabled",true). attr ("value", "\u9a8c\u8bc1\u4e2d..")); CheckMail2 (); CHECKPWD2 (); Checkcaptcha (); if(Auth_email = = 1 && auth_pwd = = 1 && auth_captcha = 1) { $(". Btn-login"). attr ("Disabled",true). attr ("value", "\u767b\u5f55\u4e2d..")); $(". Form-reg"). Submit ()}Else { $(". Btn-login"). attr ("Disabled",false). attr ("value", "\u767b\u5f55"); return false }}functionCheckSubmit3 () {$ (". Btn-reg"). attr ("Disabled",true). attr ("value", "\u9a8c\u8bc1\u4e2d..")); CheckMail2 (); Checkcaptcha (); if(Auth_email = = 1 && auth_captcha = 1) { $(". Btn-reg"). attr ("Disabled",true). attr ("value", "\u5904\u7406\u4e2d..")); $(". Form-reg"). Submit ()}Else { $(". Btn-reg"). attr ("Disabled",false). attr ("value", "\u627e\u56de\u5bc6\u7801"); return false }}functionCheckSubmit4 () {$ (". Btn-reg"). attr ("Disabled",true). attr ("value", "\u9a8c\u8bc1\u4e2d..")); CHECKPWD2 (); Checkcaptcha (); if(Auth_pwd = = 1 && auth_captcha = 1) { $(". Btn-reg"). attr ("Disabled",true). attr ("value", "\u5904\u7406\u4e2d..")); $(". Form-reg"). Submit ()}Else { $(". Btn-reg"). attr ("Disabled",false). attr ("value", "\u91cd\u7f6e\u5bc6\u7801"); return false }}functionCheckSubmit5 () {$ (". Btn-reg"). attr ("Disabled",true). attr ("value", "\u9a8c\u8bc1\u4e2d..")); Checkcaptcha (); if(Auth_captcha = = 1) { $(". Btn-reg"). attr ("Disabled",true). attr ("value", "\u5904\u7406\u4e2d..")); $(". Form-reg"). Submit ()}Else { $(". Btn-reg"). attr ("Disabled",false). attr ("value", "\u5151\u6362"); return false }}
Login Authentication Js;js Verify the mailbox authentication password