Join the social network of Tech Nerds, increase skill rank, get work, manage projects...
 
Node is saved as draft in My Content >> Draft
  • Abort previous ajax request before giving other

    • 0
    • 0
    • 0
    • 0
    • 0
    • 0
    • 0
    • 0
    • 0
    Comment on it

    To abort previous ajax request before giving another

      var lastXHR;
        $("#ccode2").change(function (){
    
            lastXHR && lastXHR.abort && lastXHR.abort();
        lastXHR=$.ajax({
            type: "POST",
            .................//your code//
                 })
            })
    

    Here lastXHR is aborted first before starting a new one.

    abort ajax abort previous ajax call stop ajax stop ajax request

 0 Comment(s)

Sign In
                           OR                           
                           OR                           
Register

Sign up using

                           OR                           
Forgot Password
Fill out the form below and instructions to reset your password will be emailed to you:
Reset Password
Fill out the form below and reset your password: