PHP FormsLesson 27Free preview
PHP Form Required
This lesson is part of PHP · All levels
Summary
Some fields do need to be filled in, such as name and e-mail. This lesson discusses the required attributes in HTML5 and their application in PHP servers. Although the browser already requires the load, validation on the server remains necessary as the actual security.
Key points
- Attributes required on input require filling before a form is sent
- Validation is mandatory on the server because the browser can disable its validation.
- Check if the field is sent
- Give an error message that indicates which field is not filled
Full lesson
Code examples and quizzes
Full lessons, code examples, and quizzes are available to subscribers. 5 questions.