That doesn't seem to do anything -- Rails keeps on chugging along and returning 
the stuff for the previous request. It's only an issue because these are 
massive requests, they take many seconds each to finish, and if you click on a 
link to load a really large one, then click on a link to load a smaller one, 
the smaller one would load first, then the larger one would wipe it out. I've 
already worked around that with a semaphore, but I'd really like to tell the 
server to quit trying!

Walter

On Apr 15, 2014, at 9:42 PM, Jason Westbrook wrote:

> 
> You can call .abort() on the transport property of Ajax, its part of the 
> internal xmlhttprequest object 
> https://developer.mozilla.org/en-US/docs/Web/API/XMLHttpRequest
> 
> so for
> 
> var foo = new Ajax.Request()
> 
> foo.transport.abort();
> 
> but YMMV as the server might still continue to process the request and the 
> abort() might only kill the callbacks but not the process in the server.
> 
> 
> 
> Jason Westbrook | T: 313-799-3770 | jwestbr...@gmail.com
> 
> 
> On Tue, Apr 15, 2014 at 6:13 PM, Walter Lee Davis <wa...@wdstudio.com> wrote:
> I've looked through the API a couple of different times, and I can't see a 
> way to do that. I've tried assigning a variable to it:
> 
>         var foo = new Ajax.Request()
> 
> but re-assigning foo to point to a different request doesn't stop the first 
> one -- it carries on like it was still there, and chews up server resources.
> 
> I've read through the source, and there's nothing there about stopping the 
> request that I can see. Any ideas?
> 
> Walter
> 
> --
> You received this message because you are subscribed to the Google Groups 
> "Prototype & script.aculo.us" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to prototype-scriptaculous+unsubscr...@googlegroups.com.
> To post to this group, send email to prototype-scriptaculous@googlegroups.com.
> Visit this group at http://groups.google.com/group/prototype-scriptaculous.
> For more options, visit https://groups.google.com/d/optout.
> 
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Prototype & script.aculo.us" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to prototype-scriptaculous+unsubscr...@googlegroups.com.
> To post to this group, send email to prototype-scriptaculous@googlegroups.com.
> Visit this group at http://groups.google.com/group/prototype-scriptaculous.
> For more options, visit https://groups.google.com/d/optout.

-- 
You received this message because you are subscribed to the Google Groups 
"Prototype & script.aculo.us" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to prototype-scriptaculous+unsubscr...@googlegroups.com.
To post to this group, send email to prototype-scriptaculous@googlegroups.com.
Visit this group at http://groups.google.com/group/prototype-scriptaculous.
For more options, visit https://groups.google.com/d/optout.

Reply via email to