Upload multiple files with FormData using AngularJS and Asp.Net MVC

前端 未结 1 1132
无人共我
无人共我 2021-01-13 02:45

I want to upload multiple files using angular js, for this I am using FormData() .

Here is my form fields

    

        
相关标签:
1条回答
  • 2021-01-13 02:59

    Change the LoadFileData function

    $scope.LoadFileData = function (files) {
            $scope.files.push(files[0]);
        };
    

    files returns a Filelist object and actual file object is at index 0.

    0 讨论(0)
提交回复
热议问题