时间:2021-07-01 10:21:17 帮助过:4人阅读
//单击执行AJAX请求操作
function clickSubmit(sendUrl, data, _sucmsg, _errmsg){
$.ajax({
type: "POST",
url: sendUrl,
dataType: "json",
timeout: 20000,
data: data,
sucmsg: _sucmsg, //????????????????????????
errmsg: _errmsg, //????????????????????????
success: function(data, textStatus) {
if (data.status == 1){
$.dialog.tips(this.sucmsg ? this.sucmsg : data.msg, 2, "32X32/succ.png", function(){
//location.reload();
});
} else {
$.dialog.alert(this.errmsg ? this.errmsg : data.msg);
}
},
error: function (XMLHttpRequest, textStatus, errorThrown) {
$.dialog.alert("状态:" + textStatus + ";出错提示:" + errorThrown);
}
});
}