calling a function having callback in for loop
问题 I want to run window.resolveLocalFileSystemURI(file,success,fail) in for loop passing different file entries and want to return resolved entries in array only after I get all the entries. function resolveFiles(result,callback) { var resultData=[] window.resolveLocalFileSystemURI(result, function(entry) { resolvedGalleryImages.push(entry); callback(resolvedGalleryImages); resolvedGalleryImages=[]; }, function(e) { alert("err"+e);}); } //calling-- //@filesarr has captured images uris for(i = 0;