Trying to postpone further processing of script until ajax call is complete without using the callback. Trying something like this, but it locks. How do I do this without locking?
var loaded=false;
$.get(url,function(d){loaded=true;});
while(!loaded)  //<--locks here
  setTimeout(void(0),100);
//continue script after ajax call is complete
 
     
     
    