Is this a custom configuration form?
private
ONEGEEK.form.AbstractTextField[]
fields
The set of ONEGEEK.form.AbstractTextField fields.
The current language for the form.
Constants: Override in a ONEGEEK.forms.GValidator.options key/value map to suit environment
Options that can be overridden by plugins/translations
Merges two option object key/value pairs, into one object property map.
Apply the focus to the first form and first field (input) of the page.
Add validation to the form.
Apply the validator objects to a field
Handle's the form level errors.
Reset each form field validator.
Read in any general/specific config options from the ONEGEEK.forms.GValidator.options variable.
This function is used to validate the form
private
Object
_readOptionsRecursive(Object
opts1, Object
opts2)
Parameters:
opts1
The initial options
opts2
The custom override options
Returns:
The merged options
public
void
applyFocus()
public
void
doForm()
public
void
doFormField(DOMElement
input)
Parameters:
input
The form input/field to add validation to
private
DOMElement
getFieldByName(Object
name)
Parameters:
name
The name attribute of the element
Returns:
The DOM Element field if found, otherwise null
public
DOMElement
getForm()
Returns:
The DOM Form Element
Returns:
false in all cases except if there is a function handler specified (as a custom option), in which case void
public
void
readOptions(Object
options)
Parameters:
options
The custom override options
public
void
reset()
public
void
setOptions()
public
Boolean
validate()
Returns:
true if form is valid, false otherwise