Monitoring ajax call response
Recently I have faced a problem of monitoring all the ajax calls. Based on the response from server I have to perform some task depending on the contents of response. If the html response contains some text input field, the first text input field should be automatically focused otherwise leave the response as it is.
Here is the javascript code :
The above trick worked for me and hope it works for you guys too.
Helpful links :-
http://api.jquery.com/ajaxComplete/
Helped me in implementing the redirect functionality for ajax calls in case of session timeout. Thanks.
What a nice and clean way to do the most basic requirement.Well Done