Validate

Features:

This form validator can validate multiple forms on a page independently. I.E. it will not validate the keyword search when the enquiry form is being submitted.

If a field is found invalid, a messageBox that's specified gets turned on and the window scroll position will move to that point.

The messageBox now gets updated with a list of fields that are not valid.

You can also add custom validation to the class.

Usage:

Add the class 'required' to any field that needs validation. By Default a text field will be validated as a string. To validate as something else add either of the following as a class:

<input id="email" type="text" class="required email" />

Options:

Example:

The fields in red are required.

Male Female