From the course: HTML & CSS: Creating Forms
Unlock the full course today
Join today to access over 24,800 courses taught by industry experts.
Form validation - HTML Tutorial
From the course: HTML & CSS: Creating Forms
Form validation
- [Presenter] The goal of validation is to make sure users are entering the data you want. For example the correct number of digits in a zip code, and also to make sure they aren't sending malicious data. Validation just means you're telling them that they make a mistake after the user entered the data. There are different ways to provide validation, which can be roughly divided into three categories. We have client-side validation, which is done in the browser when the form is submitted. And this what we see an examples of with the built in browser validation. Client-side validation can can also be done inline. And this is when you get a validation message as the user is filling out the form before they click submit. Server-side validation is done after the form is submitted when the server sends back an error message. So the advantage of doing validation on the client-side, that is by the browser, is that it's a lot faster than waiting for the server to send back a response. The…
Practice while you learn with exercise files
Download the files the instructor uses to teach the course. Follow along and learn by watching, listening and practicing.