You can move the dependent calls into separate functions. Then in callback
function of first call, trigger the second call.
$.getJSON("blah", function(firstCallBack){ do your stuff ...
callNextJSON();})
function callNextJSON(){ $.getJSON(..);}
-Original Message-
From:
setting async to false *could* be an issue if the call takes a bit
(and you obviously cannot control your user's connection from their
browser to your server(, as it will fully lock up your users browser
while it waits.not exactly the best feedback to give your
visitors
On Jul 21, 8:15
2009/7/21 András Csányi :
>
> Okay. You are right and the options what you mentioned likes form me,
> but I asked hungarian web developers and they sad I have a third
> option:
> using ajaxSetup llike this:
> $.ajaxSetup({
> async: false
> });
> The problem what I see in this case that ajaxSetup
2009/7/21 MorningZ :
>
> Yeah, your first mistake is assuming that the first will be done when
> the second is called
>
> you've got two choices, one with a plugin, one without
>
> 1) with plugin... google "jQuery Ajax Queue".. it's an older plugin,
> but people have said in here that it stil
Yeah, your first mistake is assuming that the first will be done when
the second is called
you've got two choices, one with a plugin, one without
1) with plugin... google "jQuery Ajax Queue".. it's an older plugin,
but people have said in here that it still works fine
2) put the 2nd getJSO
5 matches
Mail list logo