Basically you don't want the form to be submitted unless this is checked.Using vanilla Java Script we can prevent form submission as follows: All this does is confirm before submitting the form that the checkbox is checked.
Let's build a simple form with a validation script.
In addition, be sure to check our snippets section for additional form-related scripts.
As always, we're here if you have any questions or comments.
Please send corrections and suggested improvements to [email protected] As of January 2013, Opera had the most complete support for these new input elements, followed closely by Chrome.
Firefox and Safari had moderate support, and Internet Explorer had no support at all.Form validation is the process of checking that a form has been filled in correctly before it is processed.