Skip to content

Instantly share code, notes, and snippets.

@coryjthompson
Created November 10, 2012 22:00
Show Gist options
  • Save coryjthompson/4052684 to your computer and use it in GitHub Desktop.
Save coryjthompson/4052684 to your computer and use it in GitHub Desktop.
FileTransfer Progress with PhoneGap
var fileTransfer = new FileTransfer();
fileTransfer.onprogress = function(result){
var percent = result.loaded / result.total * 100;
percent = Math.round(percent);
console.log('Downloaded: ' + percent + '%');
};
fileTransfer.download(remoteFile, localPath, successCallback, errorCallback);
@rafiqvns
Copy link

rafiqvns commented Jul 5, 2018

thank you. @coryjthompson

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment