zmathew / django-ajax-upload-widget

Provides AJAX file upload functionality for FileFields and ImageFields with a simple widget replacement in the form.
BSD 3-Clause "New" or "Revised" License
89 stars 63 forks source link

FR: Add an option to set accepted file types #19

Open asafge opened 10 years ago

asafge commented 10 years ago

Hey, It would be great if one of the settings would allow to set something like accept="image/gif" for the file input. Currently I'm just doing this: $('input[type="file"].ajax-upload').attr('accept', 'image/gif, image/jpeg, image/png'); but it would be better as an option when initializing the widget.

Thanks