Created
August 26, 2016 12:52
-
-
Save martinsam/fc0f65c8c0403376c3df0cfeef0bfd55 to your computer and use it in GitHub Desktop.
Flask Form validation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| class FooForm(Form): | |
| email = StringField( | |
| 'Email', | |
| [ | |
| validators.Length( | |
| min=3, | |
| max=40, | |
| message=u"Votre email doit comporter 3 à 40 caractères"), | |
| validators.Email('Adresse mail invalide') | |
| ]) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment