Methods summary
public
|
|
public
TextBase
|
#
setValue( string $value )
Sets control's value.
Parameters
Returns
Overrides
|
public
string
|
#
getValue( )
Returns control's value.
Returns
string
Overrides
|
public
TextBase
|
#
setEmptyValue( string $value )
Sets the special value which is treated as empty string.
Sets the special value which is treated as empty string.
Parameters
Returns
|
public
string
|
#
getEmptyValue( )
Returns the special value which is treated as empty string.
Returns the special value which is treated as empty string.
Returns
string
|
public
TextBase
|
#
addFilter( callable $filter )
Appends input string filter callback.
Appends input string filter callback.
Parameters
Returns
|
public
string
|
#
sanitize( $value )
Filter: removes unnecessary whitespace and shortens value to control's max
length.
Filter: removes unnecessary whitespace and shortens value to control's max
length.
Returns
string
|
public
Html
|
#
getControl( )
Generates control's HTML element.
Generates control's HTML element.
Returns
Overrides
|
public
TextBase
|
#
addRule( mixed $operation, string $message = NULL, mixed $arg = NULL )
Adds a validation rule.
Parameters
- $operation
mixed rule type
- $message
string message to display for invalid data
- $arg
mixed optional rule arguments
Returns
Overrides
|
public static
boolean
|
#
validateLength( TextBase $control, array $range )
Length validator: is control's value length in range?
Length validator: is control's value length in range?
Parameters
- $control
TextBase
- $range
array min and max length pair
Returns
boolean
|
public static
boolean
|
#
validateEmail( TextBase $control )
Email validator: is control's value valid email address?
Email validator: is control's value valid email address?
Parameters
Returns
boolean
|
public static
boolean
|
#
validateUrl( TextBase $control )
URL validator: is control's value valid URL?
URL validator: is control's value valid URL?
Parameters
Returns
boolean
|
public static
|
|
public static
boolean
|
#
validateRange( TextBase $control, array $range )
Rangle validator: is a control's value number in specified range?
Rangle validator: is a control's value number in specified range?
Parameters
- $control
TextBase
- $range
array min and max value pair
Returns
boolean
|