javascript - How to change Header Parameters while using angular-file-upload for uploading multiple files -


i have requirement add file name in header while uploading each file. using single uploader selecting multiple files. tried doing

 $scope.uploader.onafteraddingfile = function (fileitem) {        $scope.uploader.headers.filename = fileitem.name;  }; 

but not changing. can please help?

try this:

$scope.uploader.queue[$scope.uploader.queue.length - 1].file.name = "prefix-" + fileitem.file.name; 

Comments

Popular posts from this blog

user interface - how to replace an ongoing process of image capture from another process call over the same ImageLabel in python's GUI TKinter -

javascript - Restarting Supervisor and effect on FlaskSocketIO -

c# - Breakout Brick Collision -