inputEx - StringField Usage
Basic StringField creation
Use the following code to create a basic inputEx field.
With a default value
You can set a default value by specifying the 'value' property in the options object.
Changing the size
You can set the size of the input.
Tooltip icons
InputEx can add a icon next to each field that will represent the state of the field. A tooltip is added on
Required
If the 'required' property is set, the 'validate' method will return false if the field is empty. In a form, the 'validate' method will be called on each field and will return false if at least one field doesn't validate.
Numbers only
If the 'numbersOnly' property is set, the field will only accept numbers !
Regular Expression
The basic Field class can use regular expressions to validate the field content. Here is an example with this wonderful email regular expression (note that there is an Email Field class).
Enabling/Disabling inputs
You can call the methods 'disable' or 'enable' to set the state of the field.
Updated event
How to listen to the updated event :