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


I have this requirement to add file name in header while uploading each file. I am using a single uploader for selecting multiple files.
I tried doing this

 $scope.uploader.onAfterAddingFile = function (fileItem) {
       $scope.uploader.headers.fileName =;

But its not changing. Can anyone please help?


Try with this:

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

Answered By – mlivan

Answer Checked By – Katrina (AngularFixing Volunteer)

Leave a Reply

Your email address will not be published.