]>
iEval git - gruntmaster-page.git/blob - js/90-form.js
2 $('.jsform > input[type="submit"]').on('click', function(e
){
3 var form_data
= new FormData(this.parentElement
);
4 var form
= this.parentNode
;
5 var xhr
= new XMLHttpRequest();
6 xhr
.open(form
.getAttribute('method'), form
.getAttribute('action'));
7 xhr
.onload = function() {
8 $('#result')[0].innerHTML
= this.responseText
;
10 xhr
.onerror = function() {
11 $('#result')[0].innerHTML
= 'Error!';
13 window
.scrollTo(0, 0);
14 $('#result')[0].innerHTML
= 'Loading...';
This page took 0.046793 seconds and 4 git commands to generate.