Q&A
Ask and answer questions to make information more available to wider audiences.
Cayden Swiss @swisscayden   04, Jul 2023 12:00 AM
ajaxStart() function
Can you explain about ajaxStart() functions?
answers 2
 
Answer 1
Nathanael Chandler @chandlernathanael   07, Jul 2023 04:09 PM
For example, suppose you have an online shopping cart application that allows customers to add items to their shopping cart when they are ready to checkout. An ajaxStart() event could be used to trigger a shopping cart initialization routine when the user first visits the application, or any time a new shopping cart is about to be initialized.

Similarly, a shopping cart termination routine could be triggered when the user is finished shopping, or whenever a shopping cart is no longer needed.

 
Answer 2
Nathanael Chandler @chandlernathanael   07, Jul 2023 04:08 PM
The ajaxStart() event is a global event that occurs when an Ajax request begins, assuming no other Ajax requests are presently active. The ajaxStart() event can also be used to cancel a previously called Ajax callback or to start a new one.