I've got that piece of code:
var result;
$.when(result=make_req("GET", "ajax.php?request=opendiv", true, null, null)).done(alert(result));
Can you tell me, why does alert show 'undefined'?
make_req() makes some ajax call, it works properly and returns good value when I call it alone.
I want to store results from make_req in the variable 'result' and then use it.