article:
Logo Generator
article:
Plugin: nestedSortable

Plugin: validationEngine

Advertisement

Validation engine is a Javascript plugin aimed at the validation of form fields in the browser (IE 6-8, Chrome, Firefox, Safari, Opera 10). The plugin provides visually appealing prompts that grab user attention on the subject matter.

Validations range from email, phone, and URL, to more complex calls such as ajax processing or custom javascript functions. Bundled with many locales, the error prompts can be translated into the language of your choice.


Usage

implement jQuery

<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.7.2/jquery.js" type="text/
javascript"></script>

Include jquery.validationEngine and its locale
<script src="js/jquery.validationEngine-en.js" type="text/javascript" charset="utf-8"></script>
<script src="js/jquery.validationEngine.js" type="text/javascript" charset="utf-8"></script>

include the desired theme
<link rel="stylesheet" href="css/validationEngine.jquery.css" type="text/css"/>

Field Validations
Validations are defined using the field's class attribute. Here are a few examples showing how it happens:
<input value="someone@nowhere.com" class="validate[required,custom[email]]" type="text" name="email" id="email" />
<input value="2010-12-01" class="validate[required,custom[date]]" type="text" name="date" id="date" />
<input value="too many spaces obviously" class="validate[required,custom[onlyLetterNumber]]" type="text" name="special" id="special" />

For more details about validators, please refer to the website


Rules

- field.id is unique across the page
- From 2.2.4 and up, jquery 1.6+ is required because of prop()
- for simplicity and consistency field.id and field.name should match (except with minCheckbox and maxCheckbox validators)
- spaces or special chars should be avoided in field.id or field.name
- use lower case for input.type ie. text, password, textarea, checkbox, radio
- validators are evaluated from left to right, use the Ajax validator last e.g.
- validate[custom[onlyLetter],length[0,100],ajax[ajaxNameCall]]
- please use only one Ajax validator per field!
- JSON services should live on the same server (or you will get into browser security issues)
- in a perfect RESTful world, http GET is used to READ data, http POST is used to WRITE data: which translates into Ajax validations should use GET, the actual form post should use a POST request.



Plugin: validationEngine



source
download
demo
validationEngine with modal & dialog plugins

Advertisement
Tags: plugin, validation, js, jquery, web, css, form, element, design, interactiv

Leave a Comment

No Comment

© Creative3x Ltd.