-
Notifications
You must be signed in to change notification settings - Fork 40
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Upload file automatically #68
Comments
Use (fileChange) for when one file changes or (filesChange) when multiple files change |
Thank you very much for the answer, but when I use fileChange it throws me an error, for example in the input of the file I use the (fileChange) = "uploadFiles", with the uploadFiles () function of the documentation example and it throws me an error and not Upload the file. It is literally not an error, it just doesn't load the file and throws me a blocked request message (CORS), but when the uploadFiles () function assigned it to a separate button, the file is uploaded without any problem and doesn't throw me any error by CORS. |
(fileChange) = "uploadFiles($event)" CORS is a server issue on you. You are having newbie issues. Good luck. Read like crazy |
Thank you very much for your answer, but that is not the solution that helps me, because I could already capture the file just by sending (fileChange) = "uploadFiles (files)", but it is the FormData who does not update in real time, Since if I create a FormData in the uploadFiles function and assign it File manually (sendFormData.append ("file", file [0])) it automatically loads, my most specific question is whether there is any more automatic functionality to do this . In ng2-file-upload I used onAfterAddingFile to automatically generate the file upload, I thought that since this plugin was based on ng2-file-upload I was going to have some similar functionality, thank you very much for your answers and for your time! Regards! |
‘’’ ‘’’ https://github.com/AckerApple/angular-file/blob/master/README.md#practical-example I’m a very direct person, here comes some more of that. I see you trying to be most kind, it is most appreciated. But in some fashion you still giving me grief with your expectations comments. This code is better structured and does not over do its duties like that other upload package. Read the docs. Package does the job fantastically well. |
@AckerApple which event helps to avoid same name file upload? |
Basic JavaScript FormData has a name attribute. Each file has its own name. Name collisions are on you |
Dear.
Can someone help me with a problem that I have when uploading a file, what happens is that I want to automatically load the file when selecting the file in the input field, it is possible, in the extension ng2-file-upload (ng2FileSelect [uploader]="fileUploader") I did it without any problem, but I don't find it when trying to implement it in this extension.
Beforehand thank you very much
The text was updated successfully, but these errors were encountered: