Is It Possible To Submit Form Twice?
I have the situation like updating values to db when form is submitted.Issue here is, Total is calculated only after form is submitted. so i have to update the calculated total aga
Solution 1:
You can use ajax to submit form twice, see following code:
function submit() {
var form = $('#your-form');
$.ajax({
type: 'POST',
url: form.attr('action'),
data: form.serialize(),
success: function(data) {
$.ajax({
type: 'POST',
url: form.attr('action'),
data: form.serialize(),
success: function(data) {
}
});
}
});
}
Post a Comment for "Is It Possible To Submit Form Twice?"