Ajax JQuery responses order problem....

Posted by Parhs on Stack Overflow See other posts from Stack Overflow or by Parhs
Published on 2010-03-15T14:17:36Z Indexed on 2010/03/15 14:19 UTC
Read the original article Hit count: 240

Filed under:
|

Hello !!! I am searching 3 hours and didnt find anything.... i have this code which is called at an onChange event of an

        function group_changed(obj)

{ $.ajaxSetup({async:false}); $.post("/medilab/personnel/groups/getGroupRightsAjax",{ 'group.id': obj.options[obj.selectedIndex].value }, function(data){ $("#div_rights").html(data); });

} This works fine but if i set async:true sometimes the result doesnt match the selection... I guess that this is happening because some requests are lost or that the responses dont come in order.....

Any idea what to do to keep it asynchronous?

© Stack Overflow or respective owner

Related posts about AJAX

Related posts about jQuery