blog

  • Home
  • blog
  • 10 jQuery Form Validation Plugins

10 jQuery Form Validation Plugins

HTML5 introduced new form attributes so that the browser could validate forms natively. With CSS3 and JavaScript you can realize a basic form validation without the need of a plugin – as described in this article. But this has a few restrictions:

  • Error messages are left to the browser itself, you can only provide titles of input fields
  • You aren’t able to customize the styling of error messages
  • You’ll have to create patterns for input fields yourself

The following 10 jQuery form validation plugins set themselves the goal of customizing error messages and styling, as well as simplifying the creation of validation rules.

1. Parsley

An extensible plugin that offers ordinary options like localization and custom validation rules, but also a remote Ajax validation. The documentation is clean and easy to read and the project is actively maintained. Validation rules can be controlled using HTML5 form or custom data attributes.

See the Pen Parsley Plugin Demo by SitePoint (@SitePoint) on CodePen.

Website
Source code

2. jQuery Form Validator

A modular plugin, that offers a basic set of validation rules by default and lets you load further modules on demand. For example: a file validator when uploading files, but also date, security or location modules. It also allows you to provide input suggestions. The validation is controlled with HTML5 data attributes.

See the Pen jQuery Form Validator Plugin Demo by SitePoint (@SitePoint) on CodePen.

Website
Source code

3. jQuery Validation Plugin

One of the first validation plugins from 2006. It lets you specify custom validation rules using HTML5 attributes or JavaScript objects. It also has a lot of default rules implemented and offers an API to easily create rules yourself. Finding detailed information about the plugin may be hard at first and it’s limited to jQuery 1.x, but they promised to make it better – see this campaign.

See the Pen jQuery Validation Plugin Demo by SitePoint (@SitePoint) on CodePen.

Website
Source code

Continue reading %10 jQuery Form Validation Plugins%

LEAVE A REPLY