бредово конечно, но:
var tmp2;
var id = sometime;
$.ajax({
type: "POST",
url: "toServer1/",
data: "id="+id,
success: function(msg){
toserver2(msg);
}
});
function toserver2(tmp)(){
if(tmp == "1"){
$.ajax({
type: "POST",
url: "toServer2/",
data: "tmp="+tmp,
success: function(msg){
toserver3(msg);
}
});
}
}
function toserver3(tmp)(){
if(tmp == "2"){
$.ajax({
type: "POST",
url: "toServer3/",
data: "tmp="+tmp,
success: function(msg){
toserver4(msg);
}
});
}
}
и тд