angular-drag-n-drop-directive icon indicating copy to clipboard operation
angular-drag-n-drop-directive copied to clipboard

How I can restrict the file extension?

Open ZeroQool007 opened this issue 4 years ago • 1 comments
trafficstars

Hello!

How I can restrict the file extension?

thanks. kind regards

ZeroQool007 avatar Jan 16 '21 12:01 ZeroQool007

you can use a accept="" attribute on the input.

Example limiting to PDF

<input type="file" accept="application/pdf" #fileDropRef id="fileDropRef" multiple (change)="fileBrowseHandler($event.target.files)" />

Moeller35 avatar Mar 23 '21 18:03 Moeller35