TypeError: e[h] is not a function
javascript, jquery
Solution
Remove the line below.
<input type="submit" name="login" id="submit" style="visibility:hidden" />
Update:
Or if you have to use the submit input, then you need to change the id `submit` to something else. The reason is that if you have an input element with `id` of `submit`, it will set a `submit` property to the form with the HTMLInputElement. So you could not call the `.submit` method on the HTMLFormElement.
Problem
I've been using jquery 1.6 with no problem. Today I switched to jquery 1.8 and suddenly I am getting this error when trying to submit a form: ``` TypeError: e[h] is not a function. ``` Form: ``` <form method="post" action="login?login" name="login" id="login"> <input class="input" type="text" name="user_mail" id="user_mail" autocomplete="on" /> <input class="input" type="password" name="password" id="password" autocomplete="off" /> <a class="green_button" href="javascript:void(0)" id="login_button">Login</a> <input type="submit" name="login" id="submit" style="visibility:hidden" /> </form> <script language="javascript"> $("#login_button").click(function(){ $("#login").submit(); }); </script> ``` Am I missing something? Thanks!