jQuery Validation Plugin
JavaScript HTML CSS PHP
Latest commit 3861ce2 Sep 23, 2016 @AbdullahObaid AbdullahObaid committed with staabm Localization: fixed typo in arabien language file.
the message is not appearing because {0} is written (0}.
Closes #1868.
Permalink
Failed to load latest commit information.
.github Chore: add issue and pull request templates. Closes #1726. Mar 17, 2016
build Build: Added contact information for MS CDN Apr 1, 2016
demo Demo: add links to Bootstrap and Semantic-UI demos to index.html Jul 22, 2016
lib Core: Use jQuery 1.7+ on/off, add destroy method Jun 17, 2015
src Localization: fixed typo in arabien language file. Sep 26, 2016
test Tests: Upgrade QUnit to 2.0. Jul 22, 2016
.editorconfig Use LF to match jQuery Styleguide Jan 16, 2014
.gitattributes Use LF to match jQuery Styleguide Jan 16, 2014
.gitignore Build: Cleanup gitignores, jscs settings, package descriptions Oct 17, 2014
.jscsrc Build: Cleanup gitignores, jscs settings, package descriptions Oct 17, 2014
.jshintignore JSHint: Extract configuration to dotfiles Jan 23, 2014
.jshintrc Build: Bump and merge JSHint/JSCS config May 27, 2014
.travis.yml Build: bump dev-dependencies to latest versions Jul 22, 2016
CONTRIBUTING.md Core: added doc reference to jQuery.validator.methods Nov 24, 2015
Gruntfile.js UMD: Better support for CommonJS. Sep 1, 2016
LICENSE.md Build: Add a copy of the MIT license Jun 16, 2015
README.md Readme: removing note about our search for a maintainer. Mar 30, 2016
bower.json Core: Use jQuery 1.7+ on/off, add destroy method Jun 17, 2015
changelog.md Build: Updating the master version to 1.15.2-pre. Jul 22, 2016
package.json Tests: Upgrade QUnit to 2.0. Jul 22, 2016
validation.jquery.json Build: Cleanup gitignores, jscs settings, package descriptions Oct 17, 2014

README.md

jQuery Validation Plugin - Form validation made easy

Build Status devDependency Status Join the chat at https://gitter.im/jzaefferer/jquery-validation

The jQuery Validation Plugin provides drop-in validation for your existing forms, while making all kinds of customizations to fit your application really easy.

Getting Started

Downloading the prebuilt files

Prebuilt files can be downloaded from http://jqueryvalidation.org/

Downloading the latest changes

The unreleased development files can be obtained by:

  1. Downloading or Forking this repository
  2. Setup the build
  3. Run grunt to create the built files in the "dist" directory

Including it on your page

Include jQuery and the plugin on a page. Then select a form to validate and call the validate method.

<form>
    <input required>
</form>
<script src="jquery.js"></script>
<script src="jquery.validate.js"></script>
<script>
$("form").validate();
</script>

Alternatively include jQuery and the plugin via requirejs in your module.

define(["jquery", "jquery.validate"], function( $ ) {
    $("form").validate();
});

For more information on how to setup a rules and customizations, check the documentation.

Reporting issues and contributing code

See the Contributing Guidelines for details.

IMPORTANT NOTE ABOUT EMAIL VALIDATION. As of version 1.12.0 this plugin is using the same regular expression that the HTML5 specification suggests for browsers to use. We will follow their lead and use the same check. If you think the specification is wrong, please report the issue to them. If you have different requirements, consider using a custom method. In case you need to adjust the built-in validation regular expression patterns, please follow the documentation.

License

Copyright © Jörn Zaefferer
Licensed under the MIT license.