What validation for fileupload?

jfquestiaux

Well-Known Member
I have an Ajax fileupload for which I want to validate to force user to upload at least one file.

I tried the "notempty" validation, but the validations always fails, even if there is an uploaded file.
Is there a(nother) way?

This is for Fabrik 3.1RC1
 
Thanks, but it is not exactly the same issue: I know that when SOME validation fails on a form with a fileupload element, the selected file gets lost. That seems to be the way browsers work.
In my case, I am looking for a "notempty" validation for the fileupload itself. The "notempty" plugin does not work.
 
the ajax upload element is slightly different to the normal one, as we do have a reference to the fileuploaded (as its uploaded before the form is processed) - this might also explain why the validations aren't applied or applied incorrectly.
I'll raise a ticket on this one (https://github.com/Fabrik/fabrik/issues/1043).
Sorry I'm only raising tickets at the moment but there's a lot of pro outstanding issues, and at the moment I just want to ensure everyone know's I'm aware of their issues and that they will be looked at.

-Rob
 
We are in need of some funding.
More details.

Thank you.

Members online

Back
Top