Hi,

(Hit send too fast.)  This article[1] from the unofficial wiki may be
useful as well.

[1] http://proto-scripty.wikidot.com/prototype:how-to-bulletproof-ajax-requests

-- T.J.

On Apr 14, 2:19 pm, "T.J. Crowder" <t...@crowdersoftware.com> wrote:
> Hi,
>
> Exceptions in the Ajax callbacks are caught by Prototype and routed to
> your onException handler, if you have one.  Details in the docs[1].
> This is specific to the Ajax callbacks, not event handlers generally.
>
> [1]http://prototypejs.org/api/ajax/options
>
> HTH,
> --
> T.J. Crowder
> tj / crowder software / com
> Independent Software Engineer, consulting services available
>
> On Apr 14, 1:39 pm, Dennis <beckerden...@gmail.com> wrote:
>
> > Hey everybody,
>
> > my problem is the following: i have a lot of javascript code that
> > should be executed after an ajax request:
>
> > sendRequest: function(url, method, [...]){
> >                 new Ajax.Request (url, {
> >                         method: method,
> >                         requestHeaders: {Accept: 'application/json'},
> >                         onSuccess: this.interpretResponse.bind(this),
> >                         onFailure: this.handleRequestFailure.bind(this)
> >                 });
>
> >         },
>
> >         interpretResponse: function(response){
> >                 //a lot of js code
> >                //alert(undefinedVariable);
> >         }
>
> > Now, everything that sits behind the interpretResponse function isn't
> > correctly checked either by Firebug nor by Firefox. Let's say we put
> > alert(something) in it and 'something' is not defined - no error is
> > shown.
>
> > We tried the same situation with pure javascript and it wasn't a
> > problem.
>
> > Any ideas?
> > Thanks!
>
>
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Prototype & script.aculo.us" group.
To post to this group, send email to prototype-scriptaculous@googlegroups.com
To unsubscribe from this group, send email to 
prototype-scriptaculous+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/prototype-scriptaculous?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to