In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-01-19 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Development >
Share
Shulou(Shulou.com)06/01 Report--
This article mainly introduces the use of ajaxError (), has a certain reference value, interested friends can refer to, I hope you can learn a lot after reading this article, the following let the editor take you to understand it.
.ajaxError () description: registers a callback handler, which is an Ajax Event, when an Ajax request goes wrong.
Whenever an Ajax request goes wrong, jQuery triggers the ajaxError event, and at this point all handlers are registered and executed using the .ajaxError () method. Note: the handler processor here invokes cross-domain scripts and cross-domain JSONP requests.
Observe this method and establish a basic Ajax load request:
Trigger
Bind event handlers on document:
$(document) .ajaxError (function () {
("div.log") .text ("Triggered ajaxError handler.")
})
Now we can use any jQuery method to build an Ajax request:
$("button.trigger") .click (function () {
$("div.result") .load ("ajax/missing.html")
})
This message is displayed when the user clicks the button and the Ajax request fails because the requested file does not exist.
But starting with jQuery 1.8, the .ajaxComplete () method can only be bound to document elements.
Note that this paragraph has been deleted from the original text on the official website: because .ajaxComplete () is executed as a jQuery object instance method, we can use the this keyword as the specified element in the callback function.
Thank you for reading this article carefully. I hope the article "what's the use of ajaxError ()" shared by the editor will be helpful to everyone? at the same time, I also hope that you will support us and pay attention to the industry information channel. More related knowledge is waiting for you to learn!
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.