From 0e8497a7806ed8f87adbdc4ea44e9971d40b1ce9 Mon Sep 17 00:00:00 2001 From: Craig Davis Date: Sat, 22 Jan 2011 20:23:51 -0600 Subject: [PATCH] Adding note about validateCallback to the validation readme --- VALIDATION.md | 32 ++++++++++++++++++++++++++++++-- 1 file changed, 30 insertions(+), 2 deletions(-) diff --git a/VALIDATION.md b/VALIDATION.md index 1e9d561..d2d0b99 100644 --- a/VALIDATION.md +++ b/VALIDATION.md @@ -32,7 +32,6 @@ as a parameter when you call uniform(). ## Uni-Form Settings - * prevent_submit (false) Set this to true to prevent the form from submitting if there are outstanding errors in the form @@ -59,4 +58,33 @@ as a parameter when you call uniform(). List of html elements that will be treated with Uni-Form highlighting and validation (if enabled) * default_value_color ("#AFAFAF") - HEX color used to display the default data in the background of empty text inputs \ No newline at end of file + HEX color used to display the default data in the background of empty text inputs + +## Validators + +* required +* validateMinLength +* validateMin +* validateMaxLength +* validateMax +* validateSameAs +* validateEmail +* validateUrl +* validateNumber +* validateInteger +* validateAlpha +* validateAlphaNum +* validatePhrase +* validatePhone +* validateDate +* validateCallback + +Validators what require a parameter, such as validateMinLength, take that parameter +as a class name following the validator in the format of _val-{value}_. + +## validateCallback + +The validateCallback is a special validator. See the demo/callback.html file for example +use. It allows you to define a custom callback to an input without having to add a new +validator type to the library. +