FileField Validation Using Flask Not Working Properly
I'm using Flask-WTF to validate my form, but for the FileField, it's not validating properly, it doesn't detect the file. form.py class addVendorForm(Form): name = StringField(
Solution 1:
Change
form = addVendorForm(request.form)
To
form = addVendorForm()
Solution 2:
I don't see the FileRequired()
validators in the doc.
Have you tried Required()
?
Post a Comment for "FileField Validation Using Flask Not Working Properly"