jQuery input submit code example
Example 1: jquery submit form
$('form').submit();
$('form').submit(function(e){
e.preventDefault();
e.currentTarget.submit();
});
Example 2: jquery submit form
<input type='button' value='Submit form' onClick='submitDetailsForm()' />
<script language="javascript" type="text/javascript">
function submitDetailsForm() {
$("#formId").submit();
}
</script>
Example 3: jquery get value of input submit
$("#submit_button").click(function() {
var data = $("#my_form").serialize();
data += data.length ? "&" : "";
data += escape($(this).attr("name"))+"="+escape($(this).val());
return false;
});