0
I created a API Java to fileupload any file, it’s something simple, it just takes any selected image and sends to C: images, I’m using with Angular 4, my goal is to make this implementation with video, but I had tried before with images as they are easier to find available codes and ready with image implementation.
I went to do with video and it didn’t work, I believe it’s something I should change in my Angular Front-end. So see the code below;
This is my service;
export class MidiaService {
midiasUrl = 'http://localhost:8080/midias';
constructor(private http: Http) { }
urlUploadAnexo(): string {
return `${this.midiasUrl}/files`;
}
And this is my component:
get urlUploadAnexo() {
return this.midiaService.urlUploadAnexo();
}
And this is my page:
<div class="ui-g-6 ui-md-3 ui-fluid">
<label>URL</label>
<p-fileUpload name="files" mode="basic" auto="true" maxFileSize="1000000000000000000000000000"
chooseLabel="Anexar" accept="image/*,application/*"
[url]="urlUploadAnexo"
></p-fileUpload>
</div>
I think the place where I should change to accept video files should be on the page, would anyone have a suggestion how to make the change? please!
<p-fileUpload>
is not a tag HTML5. You can specify which framework you are using?– mercador
and can also explain better what did not work
– mercador