namespace Form.Element
Instance methods
-
activate
Form.Element#activate(element) -> ElementGives focus to a form control and selects its contents if it is a text input.
-
clear
Form.Element#clear() -> Element Form.Element.clear(element) -> ElementClears the contents of a text input. Returns the element.
This method can be called either as an instance method or as a generic method. If calling as a generic, pass the instance in as the first argument.
-
disable
Form.Element#disable() -> Element Form.Element.disable(element) -> ElementDisables a form control, effectively preventing its value from changing until it is enabled again.
This method can be called either as an instance method or as a generic method. If calling as a generic, pass the instance in as the first argument.
-
enable
Form.Element#enable() -> Element Form.Element.enable(element) -> ElementEnables a previously disabled form control.
This method can be called either as an instance method or as a generic method. If calling as a generic, pass the instance in as the first argument.
-
getValue
Form.Element#getValue() -> String | Array Form.Element.getValue(element) -> String | ArrayReturns the current value of a form control.
A string is returned for most controls; only multiple
selectboxes return an array of values.The global shortcut for this method is
$F.Alias of:
$FThis method can be called either as an instance method or as a generic method. If calling as a generic, pass the instance in as the first argument.
-
present
Form.Element#present() -> Element Form.Element.present(element) -> ElementReturns
trueif a text input has contents,falseotherwise.This method can be called either as an instance method or as a generic method. If calling as a generic, pass the instance in as the first argument.
-
serialize
Form.Element#serialize() -> String Form.Element.serialize(element) -> StringReturns a URL-encoded string representation of a form control in the
name=valueformat.This method can be called either as an instance method or as a generic method. If calling as a generic, pass the instance in as the first argument.
-
setValue
Form.Element#setValue(value) -> Element Form.Element.setValue(element, value) -> ElementSets
valueto be the value of the form control. Returns the element.This method can be called either as an instance method or as a generic method. If calling as a generic, pass the instance in as the first argument.
