jQuery ajaxError() 方法
jQuery 教程
· 2019-03-28 15:18:52
实例
当 AJAX 请求失败时,触发一个警告框:
$(document).ajaxError(function(){
alert("一个错误发生!");
});
定义和用法
ajaxError() 方法规定 AJAX 请求失败时运行的函数。
注意:自 jQuery 版本 1.8 起,该方法只被附加到文档。
语法
$(document).ajaxError(function(event,xhr,options,exc))
| 参数 | 描述 |
|---|---|
| function(event,xhr,options,exc) |
必需。规定当请求失败时运行的函数。 额外的参数:
|
点击查看所有 jQuery 教程 文章: https://codercto.com/courses/l/35.html
SCWCD Exam Study Kit Second Edition
Hanumant Deshmukh、Jignesh Malavia、Matthew Scarpino / Manning Publications / 2005-05-20 / USD 49.95
Aimed at helping Java developers, Servlet/JSP developers, and J2EE developers pass the Sun Certified Web Component Developer Exam (SCWCD 310-081), this study guide covers all aspects of the Servlet an......一起来看看 《SCWCD Exam Study Kit Second Edition》 这本书的介绍吧!