📜  ajax 发布取消请求 - Javascript 代码示例

📅  最后修改于: 2022-03-11 15:01:54.237000             🧑  作者: Mango

代码示例1
var xhr = $.ajax({
    type: "POST",
    url: "some.php",
    data: "name=John&location=Boston",
    success: function(msg){
       alert( "Data Saved: " + msg );
    }
});

//kill the request
xhr.abort()