Limit or validate file type before submitting and other suggestions :)
-
Firstly, great plugin thanks!
I have a couple of suggestions for making it even better:
1. Allow for only uploading specified file types using jQuery Validation Plugin and the bundled additional-methods.js.
It seems that all is required is to include the js file and then add ‘accept=”mimetype,mimetype,mimetype”‘ to the file input, for example:
<input type=”file” name=”files[]” id=”ug_photo” class=”required” accept=”image/*”>
I suppose the best would be to automatically add the allowed mimetypes to file inputs, but even a way to manually add ‘accept=”image/*”‘ or whatever to the field would be great!
See https://jqueryvalidation.org/accept-method
2. Allow for email and url type fields, not just text, so that these too can be validated using the plugin.
3. Allow for removing the form title, for example:
[fu-upload-form title=””]
Thanks for reading!
- The topic ‘Limit or validate file type before submitting and other suggestions :)’ is closed to new replies.