Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to filter the file types in primeng p-fileupload component

I am trying to filter the file dialogue window using p-fileUpload from primeng. I saw an example to to filter images as image/* and it works but i want ti filter for excel files. I tried file/excel, file/*.xls etc, but no help. Need help.

like image 203
Mickey Avatar asked Jan 04 '23 02:01

Mickey


1 Answers

we can filter by required type like this

accept=".xlsx,.pdf,.csv,.xls"
like image 55
Atchutha rama reddy Karri Avatar answered Jan 05 '23 17:01

Atchutha rama reddy Karri