New Post has been published on Sevenkb.com
New Post has been published on http://www.sevenkb.com/jquery/how-to-submit-an-html-login-form-on-button-click-using-jquery/
How to submit an HTML Login Form on button click using JQuery
for example we have a Login form with ID “login_form” now we nee to submit this form on click of a Button with ID “submit_btn” , following example explain.
Form:
<form id="login_form" action="login.php"> <input type="text" name="username" id="username" /> <input type="password" name="password" id="password" /> <input type="button" id="submit_btn" value="Login" /> </form>
jQuery form submit:
Now with bellow code if we click on button it will trigger button onclick function which will submit the Login form.
<script type="texxt/javascript"> $('#submit_btn').click(function() $('#login_form').submit(); ); </script>














