Home > php教程 > php手册 > body text

解析ajax事件的调用顺序

WBOY
Release: 2016-06-06 20:30:22
Original
1320 people have browsed it

本篇文章是对ajax事件的调用顺序进行了详细的分析介绍,需要的朋友参考下

jquery的ajax请求方法:

复制代码 代码如下:


$.ajax({
type: "GET",
dateType:"html",
url: "index.html",
error: function(msg) { alert("error"); },
complete: function(msg) { alert("complete"); },
success: function(msg) { alert("success"); }

});


jquery中各个事件执行顺序如下:
1.ajaxStart(全局事件)
2.beforeSend
3.ajaxSend(全局事件)
4.success
5.ajaxSuccess(全局事件)
6.error
7.ajaxError (全局事件)
8.complete
9.ajaxComplete(全局事件)
10.ajaxStop(全局事件)
,虚拟主机,美国空间,服务器空间
Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Recommendations
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template