I need a loop that waits for an async call before continuing. Something like:
for ( /* ... */ ) { someFunction(param1, praram2, function(result) { //
Also look at this splendid library caolan / async. Your for loop can easily be accomplished using mapSeries or series.
for
I could post some sample code if your example had more details in it.