When you log in to the project management system, the console prompts: uncaught typeerror document.getElementById ("LoginForm"). Submit is not a function
But checking the JS code is normal:
$ ("#loginForm"). Validate ({rules : {username : { required : true},password : {required : true,minlength : 3},code : {required : true},},messages : {username : {required: "Please enter your user name! "},password : {required : " Please enter the password! ",minlength : " Password minimum length is 3 bit! "},code : {required: " Please enter the verification code! "},}, submithandler: function (Form) { $ ("[Name=password]"). Val (MD5 ($ ("[Name=password]"). Val ())); document.getelementbyid (" LoginForm "). Submit (); });
Think of the solution, later access to the data only found that when using Form.submit () submit the form, the page submit the input cannot have name= "submit" attribute, otherwise at the time of submission, the object will and submit (), the method is confused caused the error!
This article is from the "Phoenixisland" blog, make sure to keep this source http://phoenix2012.blog.51cto.com/1799358/1677881
Sadie Project Management System login Error