Building Data-Driven Web Apps with Pyramid and SQLAlchemy Transcripts
Chapter: Client and server-side validation
Lecture: Concept: Client-side validation with HTML5

Login or purchase this course to watch this video and the rest of the course contents.
0:00 Let's review client side validation as a concept.
0:04 We saw that it's really easy to add HTML5 based validation
0:08 to our forms. All we have to do is set the type
0:11 and say whether things are required.
0:14 For example, on the first input here
0:16 we have the type is email and it's required.
0:18 The second one, the type is password, and it's required.
0:21 Password you'd typically set 'cause you're
0:24 it's really clear right away that you don't want people
0:26 to see the password, but email versus text, not so obvious.
0:30 You might as well put it in there
0:31 'cause it'll help make sure that email is actually valid
0:34 for most users. So once we have this in place
0:36 if we try to put just something like our name
0:38 where an email address is expected
0:40 it goes no no, that's not a valid email address.
0:42 You need the @. Michael is missing an @.
0:46 Real easy, just add a few requireds and types
0:49 and you'll get much better client side validation.