1 $.ajax({ 2 url: path + '/emergency/saveEmergency.do', 3 async: false,//同步,会阻塞操作 4 type: 'POST',//PUT DELETE POST 5 data: $("#saveform").serialize(), 6 success: function (result) { 7 // console.log(result); 8 if (result) { 9 window.location.reload(); 10 } 11 }, error: function(msg) { 12 for(var info in msg) 13 console.log(info + " = " + msg[info]); 14 } 15 })