flowjs / ng-flow

Flow.js html5 file upload extension on angular.js framework
http://flowjs.github.io/ng-flow/
MIT License
1.38k stars 303 forks source link

Add example showing how to use ng-flow from a controller #16

Closed decklord closed 10 years ago

decklord commented 10 years ago

I'm new to angular and I'm using ng-flow to append a file to a request with more data. ¿Could you add some example about calling $flow from a custom controller to get access to the files?

AidasK commented 10 years ago

Here you go: http://plnkr.co/edit/QL9uVb6p0NfChn28c8jS?p=preview

In this example you can access flow object in $scope.uploader.flow variable.

Read more documentation about flow.js methods here: https://github.com/flowjs/flow.js

prawn9189 commented 7 years ago

hey @AidasK , i've opened a new issue regarding something similar to this. Say i want to upload an image to the ng-flow object, but the image is taken automatically from a card scanner, and placed into a temp folder, where the file location is known, how can i automatically send that file location to be uploaded to my ng-flow. for example, my images' path is "C:\temp\MYKAD-PHOTO.JPG" i've been trying to assign it to flow.files manually, but it doesn't work... any way to help me with this?