Library: forms.js
Overview
Constructors
Nornix.FormHandler()
The NornixFormHandler class makes it easy to do form input validation and other common form tasks. Invalid fields will generate a dialog box with an error message, and the corresponding form fields will get the class "invalid". It is easy to add your own field validators. Usage instructions at http://forms.nornix.com/info/usage Warning: some strings used in the scripts will only function properly if it is served as UTF-8. If your HTML document is encoded using UTF-8 this will happen automagically. See the usage instructions.
version: @version@
methods
properties
  • String texts.okForm Default message for confirming that the form is beeing sent.
  • boolean settings.ieFixButtons Set to true to remove non-pushed submit "button" elements in IE (bug fix for IE)
Namespaces
Functions
Nornix.FormHandler.validators.validateRequired(val)
Validate required form field.
parameters
Object val form field value
returns
true on successful validation
Nornix.FormHandler.validators.validateFullName()
Validate a full name, that needs to have at least one given and one surname.
parameters
Object } val form field value
returns
true on successful validation
Nornix.FormHandler.validators.validateName()
Validate a name, only characters and hyphens are allowed.
parameters
Object } val form field value
returns
true on successful validation
Nornix.FormHandler.validators.validateEmail()
Validate an email address.
parameters
Object } val form field value
returns
true on successful validation
Nornix.FormHandler.validators.validateNumber()
Validate a number (can be any value).
parameters
Object } val form field value
returns
true on successful validation
Nornix.FormHandler.validators.validatePositiveNumber()
Validate a number, which has to be greater than zero.
parameters
Object } val form field value
returns
true on successful validation
Nornix.FormHandler.validators.validatePositiveInteger()
Validate an integer, which has to be greater than zero.
parameters
Object } val form field value
returns
true on successful validation
Nornix.FormHandler.validators.validateABC(val)
parameters
val
Objects
String Nornix.FormHandler.texts.confirmText
Default confirm text for confirm dialogs.
String Nornix.FormHandler.texts.errHeading
Default error message heading for error dialogs.
String Nornix.FormHandler.texts.okForm
Default message for confirming that the form is beeing sent.
boolean Nornix.FormHandler.settings.ieFixButtons
Set to true to remove non-pushed submit "button" elements in IE (bug fix for IE)
Generated by JsDoc Toolkit 1.4.1b on Wed, 14 May 2008 21:00:44 GMT.