PHP2Go Javascript Framework

Class SelectField

Object
   |
   +--Field
         |
         +--SelectField

class SelectField
extends Field

Defined in form.js


Field Summary
 Boolean multiple
          Indicates if the field accepts multiple choice
   
Fields inherited from class Field
fld, id, name, label, type
 
Constructor Summary
SelectField (<Object> fld)
            Class used to encapsulate operations over select inputs, accepting single or multiple choice
 
Method Summary
 void addOption(<String> value, <String> text, <Number> pos)
           Add a new option in the select field
 void clear()
           Unselect all selected options in the list
 void clearOptions()
           Remove all options off the select field
 Object getValue()
           Gets the current selected option(s).
 void importOptions(<String> str, <String> lsep, <String> csep, <Number> pos, <String> val)
           Import options to the select field from a string splitted by line and column separators.
 void removeOption(<Number> idx)
           Remove an option from the list
 void removeSelectedOptions(<Function> func, <Number> idx)
           Remove the selected options from the list.
 void selectByText(<String> text)
           Select an option by its text
 void setFirstOption(<String> value, <String> text)
           Change the first option of the select field
 void setValue(<Object> val)
           Changes the selected option(s) in the field.
 
Methods inherited from class Field
getFormElement, getMask, isEmpty, enable, disable, setDisabled, focus, beforeFocus, serialize
 

Field Detail

multiple

Boolean multiple

Constructor Detail

SelectField

SelectField(<Object> fld)

Method Detail

addOption

void addOption(<String> value, <String> text, <Number> pos)

clear

void clear()

clearOptions

void clearOptions()

getValue

Object getValue()

importOptions

void importOptions(<String> str, <String> lsep, <String> csep, <Number> pos, <String> val)

removeOption

void removeOption(<Number> idx)

removeSelectedOptions

void removeSelectedOptions(<Function> func, <Number> idx)

selectByText

void selectByText(<String> text)

setFirstOption

void setFirstOption(<String> value, <String> text)

setValue

void setValue(<Object> val)

PHP2Go Javascript Framework

Copyright © 2002-2006 by Marcos Pont
Documentation generated by JSDoc on Sun Oct 7 19:52:10 2007