tina_mvc/helpers/tina_mvc_form_helper_class.php
Builds a form, checks and validates $_POST and $_GET variables and generates HTML for you
- Package
- Tina-MVC
- Subpackage
- Core
\TINA_MVC\field
- Parent(s)
- \TINA_MVC\form_base
Properties
mixed $caption
Direct access is not supported.
- Type
- mixed
mixed $db_field
Direct access is not supported.
- Type
- mixed
mixed $db_table
Direct access is not supported.
- Type
- mixed
mixed $default_value
Direct access is not supported.
- Type
- mixed
mixed $extra_attribs
Direct access is not supported.
- Type
- mixed
string $html_form = '<div class="tina_mvc_form">%s</div>'
Use sprintf() format.
'<div class="tina_mvc_form">%s</div>'
Details- Type
- string
- Inherited_from
- \TINA_MVC\form_base::$$html_form
string $html_form_button = '<div class="tina_mvc_form_button">%s</div>'
Use sprintf() format.
'<div class="tina_mvc_form_button">%s</div>'
Details- Type
- string
- Inherited_from
- \TINA_MVC\form_base::$$html_form_button
string $html_form_error = '<div class="tina_mvc_form_error_message">%s</div>'
Use sprintf() format.
'<div class="tina_mvc_form_error_message">%s</div>'
Details- Type
- string
- Inherited_from
- \TINA_MVC\form_base::$$html_form_error
string $html_form_field_error = '<span class="tina_mvc_error">%s </span>'
Use sprintf() format.
'<span class="tina_mvc_error">%s </span>'
Details- Type
- string
- Inherited_from
- \TINA_MVC\form_base::$$html_form_field_error
string $html_form_field_message = '<div class="tina_mvc_form_field_message">%s</div>'
Use sprintf() format.
'<div class="tina_mvc_form_field_message">%s</div>'
Details- Type
- string
- Inherited_from
- \TINA_MVC\form_base::$$html_form_field_message
string $html_form_input = '<span class="tina_mvc_form_input">%s</span>'
Use sprintf() format.
'<span class="tina_mvc_form_input">%s</span>'
Details- Type
- string
- Inherited_from
- \TINA_MVC\form_base::$$html_form_input
string $html_form_label = '<span class="tina_mvc_form_label">%s </span>'
Use sprintf() format.
'<span class="tina_mvc_form_label">%s </span>'
Details- Type
- string
- Inherited_from
- \TINA_MVC\form_base::$$html_form_label
string $html_form_message = '<div class="tina_mvc_form_message">%s</div>'
Use sprintf() format.
'<div class="tina_mvc_form_message">%s</div>'
Details- Type
- string
- Inherited_from
- \TINA_MVC\form_base::$$html_form_message
string $html_form_messages = '<div class="tina_mvc_form_messages">%s</div>'
Use sprintf() format.
'<div class="tina_mvc_form_messages">%s</div>'
Details- Type
- string
- Inherited_from
- \TINA_MVC\form_base::$$html_form_messages
string $html_form_pair = '<div class="tina_mvc_form_pair">%s</div>'
Use sprintf() format.
'<div class="tina_mvc_form_pair">%s</div>'
Details- Type
- string
- Inherited_from
- \TINA_MVC\form_base::$$html_form_pair
string $html_form_radio_set = '<span class="tina_mvc_form_radio_set">%s</span>'
Use sprintf() format.
'<span class="tina_mvc_form_radio_set">%s</span>'
Details- Type
- string
- Inherited_from
- \TINA_MVC\form_base::$$html_form_radio_set
string $html_form_required_after_input = ' (required) '
Use sprintf() format.
' (required) '
Details- Type
- string
- Inherited_from
- \TINA_MVC\form_base::$$html_form_required_after_input
string $html_form_required_after_label = ''
Use sprintf() format.
''
Details- Type
- string
- Inherited_from
- \TINA_MVC\form_base::$$html_form_required_after_label
mixed $map_height
Direct access is not supported.
- Type
- mixed
mixed $map_width
Direct access is not supported.
- Type
- mixed
mixed $name
Direct access is not supported.
- Type
- mixed
mixed $options
Direct access is not supported.
- Type
- mixed
mixed $posted_value
Direct access is not supported.
- Type
- mixed
mixed $protected
Direct access is not supported.
- Type
- mixed
mixed $set_value
Direct access is not supported.
- Type
- mixed
mixed $type
Direct access is not supported.
- Type
- mixed
mixed $validation_errors
Direct access is not supported.
- Type
- mixed
array $validation_rules = array()
array()
Details- Type
- array
- Inherited_from
- \TINA_MVC\form_base::$$validation_rules
Methods
__construct(object $form, String $name = '', String $type = '', String $caption = '', String $db_table = '', String $db_field = '', String $default_value = '', mixed $extra_attribs = '', boolean $protected = FALSE) : object
Sets up the field
Name | Type | Description |
---|---|---|
$form | object | The form object the field is part of |
$name | String | A name (alphanumeric plus underscore only) |
$type | String | See the field_* classes for valid field types. You can also check the test_form_controller.php file in the samples folder |
$caption | String | Field caption used in a label (default caption is based on the name of the field) |
$db_table | String | Used to group fields |
$db_field | String | If the database is different from the field name for some reason you can set it here. |
$default_value | String | |
$extra_attribs | mixed | a string or array of strings |
$protected | boolean | Prevent load_data() from overwriting values in this field |
Type | Description |
---|---|
object | field |
add_validation(mixed $rules = FALSE) : object
Adds validation rule(s) to a field
Name | Type | Description |
---|---|---|
$rules | mixed | A single rule ( array( 'rule_name' => 'rule_parameters'.... ). See validate_* classes for valid rules. |
Type | Description |
---|---|
object | field |
add_validation_error(string $message) : object
Adds a validation error message to a field
Name | Type | Description |
---|---|---|
$message | string |
Type | Description |
---|---|
object | field |
check_validation_rule(string $v) : mixed
Checks a validation rule exists
Name | Type | Description |
---|---|---|
$v | string |
Type | Description |
---|---|
mixed |
get_error_count() : integer
Gets the number of validation errors on a field
Type | Description |
---|---|
integer |
get_post_var_name() : string
Gets the POST/GET variable name used in HTML
Type | Description |
---|---|
string |
get_value() : mixed
Getter
Gets the posted value, set value or default value (in that order)
Type | Description |
---|---|
mixed |
get_xhtml_slash() : String
Returns a XML slash for self closing tags
Inherited from: \TINA_MVC\form_base::get_xhtml_slash()Type | Description |
---|---|
String |
is_protected() : boolean
Checks if a fields value is protected and shouldn't be changed by a user
Type | Description |
---|---|
boolean |
set_caption(string $caption = '') : object
Set the caption for an input field
Name | Type | Description |
---|---|---|
$caption | string |
Type | Description |
---|---|
object | field |
set_db_field(string $field_name = '') : object
Sets the database field name (if different from the field name)
Name | Type | Description |
---|---|---|
$field_name | string |
Type | Description |
---|---|
object | field |
set_db_table(string $table_name = '') : object
Sets the db_table value for a field
Allows fields with the same db_table value to be retrieved together
Name | Type | Description |
---|---|---|
$table_name | string |
Type | Description |
---|---|
object | field |
set_default_value(mixed $value = FALSE) : object
Sets the default value for a field
Name | Type | Description |
---|---|---|
$value | mixed |
Type | Description |
---|---|
object | field |
set_extra_attribs(mixed $attribs = FALSE) : object
Sets any extra attributes you wish to pass to the form or field
Inherited from: \TINA_MVC\form_base::set_extra_attribs()Name | Type | Description |
---|---|---|
$attribs | mixed | An array of attribs or a string to be added directly into the element e.g. 'attrib="value"' |
Type | Description |
---|---|
object |
set_form(object $form_object) : object
Sets the form the field belongs to
Name | Type | Description |
---|---|---|
$form_object | object |
Type | Description |
---|---|
object | field |
set_map_height(string $h) : void
Sets the map height for field type GOOGLEMAP
Name | Type | Description |
---|---|---|
$h | string | a valid css height |
set_map_width(string $w) : void
Sets the map width for field type GOOGLEMAP
Name | Type | Description |
---|---|---|
$w | string | a valid css width |
set_name(String $name = '') : object
Checks the name for the form or field element
Inherited from: \TINA_MVC\form_base::set_name()Name | Type | Description |
---|---|---|
$name | String | The name |
Type | Description |
---|---|
object |
set_options(array $options = array()) : object
Sets options for select and radio field types
Options are array( array( 'post_value' , 'display_value' ) ). This allows feeding an array of array( 'id'=>'name' ) from a database query for example.
Name | Type | Description |
---|---|---|
$options | array |
Type | Description |
---|---|
object | field |
set_posted_value(mixed $value = FALSE) : object
Sets a posted value for the field.
Overrides the set value
Name | Type | Description |
---|---|---|
$value | mixed |
Type | Description |
---|---|
object | field |
set_set_value(mixed $value = FALSE) : object
Sets a value for the field.
Overrides the default value
Name | Type | Description |
---|---|---|
$value | mixed |
Type | Description |
---|---|
object | field |
set_type(string $t) : object
Sets the field type
Name | Type | Description |
---|---|---|
$t | string | See field_* classes for valid field types |
Type | Description |
---|---|
object | field |
set_value(mixed $value = FALSE) : object
Sets a value for the field
Name | Type | Description |
---|---|---|
$value | mixed |
Type | Description |
---|---|
object | field |
\TINA_MVC\field_checkbox
\TINA_MVC\field_fieldset_close
\TINA_MVC\field_fieldset_open
\TINA_MVC\field_googlemap
The 'value' for a Googlemap is "latitude,longitude,zoom"
- See
- object
Properties
Methods
\TINA_MVC\field_hidden
\TINA_MVC\field_password
\TINA_MVC\field_radio
\TINA_MVC\field_recaptcha
- See
- object
- See
- \TINA_MVC\http://recaptcha.net
Methods
\TINA_MVC\field_reset
Note that this does not reset reCaptcha fields.
- See
- object
Properties
Methods
\TINA_MVC\field_select
\TINA_MVC\field_submit
\TINA_MVC\field_text
You can extend the form helper by using these classes as an example. You must define a html() function which returns the escaped HTML required to display the element. Look at field_googlemap or field_recaptcha for an example of a more complex field type.
You can also define a function setup() which accepts the field object as a parameter. See field_recaptcha to see how this works.
Properties
Methods
\TINA_MVC\field_textarea
\TINA_MVC\field_textblock
\TINA_MVC\form
- Parent(s)
- \TINA_MVC\form_base
Properties
mixed $action
Tina MVC does not support direct access or class variables.
- Type
- mixed
mixed $enctype
Tina MVC does not support direct access or class variables.
- Type
- mixed
mixed $error_messages
Tina MVC does not support direct access or class variables.
- Type
- mixed
mixed $fields
Tina MVC does not support direct access or class variables.
- Type
- mixed
mixed $fieldset_open
Tina MVC does not support direct access or class variables.
- Type
- mixed
mixed $form_posted
Tina MVC does not support direct access or class variables.
- Type
- mixed
string $html_form = '<div class="tina_mvc_form">%s</div>'
Use sprintf() format.
'<div class="tina_mvc_form">%s</div>'
Details- Type
- string
- Inherited_from
- \TINA_MVC\form_base::$$html_form
string $html_form_button = '<div class="tina_mvc_form_button">%s</div>'
Use sprintf() format.
'<div class="tina_mvc_form_button">%s</div>'
Details- Type
- string
- Inherited_from
- \TINA_MVC\form_base::$$html_form_button
string $html_form_error = '<div class="tina_mvc_form_error_message">%s</div>'
Use sprintf() format.
'<div class="tina_mvc_form_error_message">%s</div>'
Details- Type
- string
- Inherited_from
- \TINA_MVC\form_base::$$html_form_error
string $html_form_field_error = '<span class="tina_mvc_error">%s </span>'
Use sprintf() format.
'<span class="tina_mvc_error">%s </span>'
Details- Type
- string
- Inherited_from
- \TINA_MVC\form_base::$$html_form_field_error
string $html_form_field_message = '<div class="tina_mvc_form_field_message">%s</div>'
Use sprintf() format.
'<div class="tina_mvc_form_field_message">%s</div>'
Details- Type
- string
- Inherited_from
- \TINA_MVC\form_base::$$html_form_field_message
string $html_form_input = '<span class="tina_mvc_form_input">%s</span>'
Use sprintf() format.
'<span class="tina_mvc_form_input">%s</span>'
Details- Type
- string
- Inherited_from
- \TINA_MVC\form_base::$$html_form_input
string $html_form_label = '<span class="tina_mvc_form_label">%s </span>'
Use sprintf() format.
'<span class="tina_mvc_form_label">%s </span>'
Details- Type
- string
- Inherited_from
- \TINA_MVC\form_base::$$html_form_label
string $html_form_message = '<div class="tina_mvc_form_message">%s</div>'
Use sprintf() format.
'<div class="tina_mvc_form_message">%s</div>'
Details- Type
- string
- Inherited_from
- \TINA_MVC\form_base::$$html_form_message
string $html_form_messages = '<div class="tina_mvc_form_messages">%s</div>'
Use sprintf() format.
'<div class="tina_mvc_form_messages">%s</div>'
Details- Type
- string
- Inherited_from
- \TINA_MVC\form_base::$$html_form_messages
string $html_form_pair = '<div class="tina_mvc_form_pair">%s</div>'
Use sprintf() format.
'<div class="tina_mvc_form_pair">%s</div>'
Details- Type
- string
- Inherited_from
- \TINA_MVC\form_base::$$html_form_pair
string $html_form_radio_set = '<span class="tina_mvc_form_radio_set">%s</span>'
Use sprintf() format.
'<span class="tina_mvc_form_radio_set">%s</span>'
Details- Type
- string
- Inherited_from
- \TINA_MVC\form_base::$$html_form_radio_set
string $html_form_required_after_input = ' (required) '
Use sprintf() format.
' (required) '
Details- Type
- string
- Inherited_from
- \TINA_MVC\form_base::$$html_form_required_after_input
string $html_form_required_after_label = ''
Use sprintf() format.
''
Details- Type
- string
- Inherited_from
- \TINA_MVC\form_base::$$html_form_required_after_label
mixed $messages
Tina MVC does not support direct access or class variables.
- Type
- mixed
mixed $method
Tina MVC does not support direct access or class variables.
- Type
- mixed
string $name = ''
Userd to construct POST variable names and CSS id's
''
Details- Type
- string
- Inherited_from
- \TINA_MVC\form_base::$$name
mixed $protected_fields
Tina MVC does not support direct access or class variables.
- Type
- mixed
mixed $validation_errors
Tina MVC does not support direct access or class variables.
- Type
- mixed
array $validation_rules = array()
array()
Details- Type
- array
- Inherited_from
- \TINA_MVC\form_base::$$validation_rules
Methods
__construct(String $name = '', String $action = '', Object $extra_attribs = array()) : void
Sets up the form
Name | Type | Description |
---|---|---|
$name | String | |
$action | String | |
$extra_attribs | Object |
add_base_fields() : void
Adds the system field
It is a WP_NONCE value and is used to check if the form was posted within the validity of the WP_NONCE.
add_error( $m = FALSE) : void
Adds an error message or messages to the form.
Name | Type | Description |
---|---|---|
$m | string the error message |
add_field(String $name = '', String $type = 'text', String $caption = '', String $db_table = '', String $db_field = '', String $default_val = '', String $extra_attribs = '') : object
Adds a field to the form
Name | Type | Description |
---|---|---|
$name | String | |
$type | String | |
$caption | String | |
$db_table | String | |
$db_field | String | |
$default_val | String | |
$extra_attribs | String |
Type | Description |
---|---|
object | field |
add_fieldset(String $name = '', String $legend = '', Mixed $extra_attribs = '') : object
Opens a fieldset
Name | Type | Description |
---|---|---|
$name | String | |
$legend | String | the caption to display |
$extra_attribs | Mixed | array of name => value pairs or a string |
Type | Description |
---|---|
object | field |
add_text(String $name = '', String $text = '', Mixed $extra_attribs = '') : object
Adds a block of text to the form
Name | Type | Description |
---|---|---|
$name | String | |
$text | String | |
$extra_attribs | Mixed | array of name => value pairs or a string |
Type | Description |
---|---|
object | field |
check_validation() : boolean
Processes validation rules attached to each field
Type | Description |
---|---|
boolean | TRUE if the rules passed |
fieldset_close(mixed $extra_attribs = '') : object
Closes an open fieldset
Name | Type | Description |
---|---|---|
$extra_attribs | mixed | array of name => value pairs or a string |
Type | Description |
---|---|
object | field |
- Todo
- Mmmm, is $extra_attribs valid for a close fieldset?
fieldset_open(String $name = '', String $legend = '', Mixed $extra_attribs = '') : object
Alias to add_fieldset()
Name | Type | Description |
---|---|---|
$name | String | |
$legend | String | the caption to display |
$extra_attribs | Mixed | array of name => value pairs or a string |
Type | Description |
---|---|
object | field |
form_posted() : boolean
Checks if the form has been posted by verifying the wp_nonce field
Type | Description |
---|---|
boolean |
get_posted_data(string $db_table = '', boolean $get_db_fields = FALSE) : array
Gets an array of data if the form was posted.
Returns boolean FALSE otherwise
Fields can be grouped by assigning a value to the db_table field property. The data returned is an array of field_name => field_value. If you want to get an array with the keys based on the db_field property, set $get_db_fields TRUE.
Name | Type | Description |
---|---|---|
$db_table | string | |
$get_db_fields | boolean |
Type | Description |
---|---|
array |
- See
- \TINA_MVC\$this->get_posted_db_value()
get_posted_db_data(string $db_table = '') : object
Gets an array of submitted data.
The field names are based on the db_field values in the field
Name | Type | Description |
---|---|---|
$db_table | string | the db_table value for the fields you want returned |
Type | Description |
---|---|
object | Description |
get_xhtml_slash() : String
Returns a XML slash for self closing tags
Inherited from: \TINA_MVC\form_base::get_xhtml_slash()Type | Description |
---|---|
String |
load_data(mixed $data = FALSE) : void
Loads an array or object of data into the form
Usually a recordset from a database in the form array( array( 'field' => 'value' ) )
Name | Type | Description |
---|---|---|
$data | mixed | array or object |
render_open_form() : string
Renders the opening form tag and any messages
Type | Description |
---|---|
string |
set_extra_attribs(mixed $attribs = FALSE) : object
Sets any extra attributes you wish to pass to the form or field
Inherited from: \TINA_MVC\form_base::set_extra_attribs()Name | Type | Description |
---|---|---|
$attribs | mixed | An array of attribs or a string to be added directly into the element e.g. 'attrib="value"' |
Type | Description |
---|---|
object |
set_name(String $name = '') : object
Checks the name for the form or field element
Inherited from: \TINA_MVC\form_base::set_name()Name | Type | Description |
---|---|---|
$name | String | The name |
Type | Description |
---|---|
object |
\TINA_MVC\form_base
- Children
- \TINA_MVC\field
- \TINA_MVC\form
Properties
string $html_form = '<div class="tina_mvc_form">%s</div>'
Use sprintf() format.
'<div class="tina_mvc_form">%s</div>'
Details- Type
- string
string $html_form_button = '<div class="tina_mvc_form_button">%s</div>'
Use sprintf() format.
'<div class="tina_mvc_form_button">%s</div>'
Details- Type
- string
string $html_form_error = '<div class="tina_mvc_form_error_message">%s</div>'
Use sprintf() format.
'<div class="tina_mvc_form_error_message">%s</div>'
Details- Type
- string
string $html_form_field_error = '<span class="tina_mvc_error">%s </span>'
Use sprintf() format.
'<span class="tina_mvc_error">%s </span>'
Details- Type
- string
string $html_form_field_message = '<div class="tina_mvc_form_field_message">%s</div>'
Use sprintf() format.
'<div class="tina_mvc_form_field_message">%s</div>'
Details- Type
- string
string $html_form_input = '<span class="tina_mvc_form_input">%s</span>'
Use sprintf() format.
'<span class="tina_mvc_form_input">%s</span>'
Details- Type
- string
string $html_form_label = '<span class="tina_mvc_form_label">%s </span>'
Use sprintf() format.
'<span class="tina_mvc_form_label">%s </span>'
Details- Type
- string
string $html_form_message = '<div class="tina_mvc_form_message">%s</div>'
Use sprintf() format.
'<div class="tina_mvc_form_message">%s</div>'
Details- Type
- string
string $html_form_messages = '<div class="tina_mvc_form_messages">%s</div>'
Use sprintf() format.
'<div class="tina_mvc_form_messages">%s</div>'
Details- Type
- string
string $html_form_pair = '<div class="tina_mvc_form_pair">%s</div>'
Use sprintf() format.
'<div class="tina_mvc_form_pair">%s</div>'
Details- Type
- string
string $html_form_radio_set = '<span class="tina_mvc_form_radio_set">%s</span>'
Use sprintf() format.
'<span class="tina_mvc_form_radio_set">%s</span>'
Details- Type
- string
string $html_form_required_after_input = ' (required) '
Use sprintf() format.
' (required) '
Details- Type
- string
string $html_form_required_after_label = ''
Use sprintf() format.
''
Details- Type
- string
string $name = ''
Userd to construct POST variable names and CSS id's
''
Details- Type
- string
Methods
\TINA_MVC\validate
Add your own validation classes by calling them 'validate_myrule' and declaring them in the TINA_MVC namespace. See the 'validate_required' for an example.
- Children
- \TINA_MVC\validate_required
- \TINA_MVC\validate_empty
- \TINA_MVC\validate_max_length
- \TINA_MVC\validate_min_length
- \TINA_MVC\validate_max_value
- \TINA_MVC\validate_min_value
- \TINA_MVC\validate_email
- \TINA_MVC\validate_sql_datetime
- \TINA_MVC\validate_sql_date
- \TINA_MVC\validate_sql_time
- \TINA_MVC\validate_equal_to_field
- \TINA_MVC\validate_less_than_field
- \TINA_MVC\validate_greater_than_field
- \TINA_MVC\validate_regexp
- \TINA_MVC\validate_recaptcha
- See
- \TINA_MVC\validate_required
Properties
$validation_message = ''
Your class should set this variable if your validation function fails
''
Details- Type
- n/a
- See
- class
Methods
\TINA_MVC\validate_email
Add your own validation classes by calling them 'validate_myrule' and declaring them in the TINA_MVC namespace. See the 'validate_required' for an example.
- Parent(s)
- \TINA_MVC\validate
Properties
$validation_message = ''
Your class should set this variable if your validation function fails
''
Details- Type
- n/a
- Inherited_from
- \TINA_MVC\validate::$$validation_message
- See
- class
Methods
\TINA_MVC\validate_empty
Add your own validation classes by calling them 'validate_myrule' and declaring them in the TINA_MVC namespace. See the 'validate_required' for an example.
- Parent(s)
- \TINA_MVC\validate
Properties
$validation_message = ''
Your class should set this variable if your validation function fails
''
Details- Type
- n/a
- Inherited_from
- \TINA_MVC\validate::$$validation_message
- See
- class
Methods
\TINA_MVC\validate_equal_to_field
Add your own validation classes by calling them 'validate_myrule' and declaring them in the TINA_MVC namespace. See the 'validate_required' for an example.
- Parent(s)
- \TINA_MVC\validate
Properties
$validation_message = ''
Your class should set this variable if your validation function fails
''
Details- Type
- n/a
- Inherited_from
- \TINA_MVC\validate::$$validation_message
- See
- class
Methods
\TINA_MVC\validate_greater_than_field
Add your own validation classes by calling them 'validate_myrule' and declaring them in the TINA_MVC namespace. See the 'validate_required' for an example.
- Parent(s)
- \TINA_MVC\validate
Properties
$validation_message = ''
Your class should set this variable if your validation function fails
''
Details- Type
- n/a
- Inherited_from
- \TINA_MVC\validate::$$validation_message
- See
- class
Methods
\TINA_MVC\validate_less_than_field
Add your own validation classes by calling them 'validate_myrule' and declaring them in the TINA_MVC namespace. See the 'validate_required' for an example.
- Parent(s)
- \TINA_MVC\validate
Properties
$validation_message = ''
Your class should set this variable if your validation function fails
''
Details- Type
- n/a
- Inherited_from
- \TINA_MVC\validate::$$validation_message
- See
- class
Methods
\TINA_MVC\validate_max_length
Add your own validation classes by calling them 'validate_myrule' and declaring them in the TINA_MVC namespace. See the 'validate_required' for an example.
- Parent(s)
- \TINA_MVC\validate
Properties
$validation_message = ''
Your class should set this variable if your validation function fails
''
Details- Type
- n/a
- Inherited_from
- \TINA_MVC\validate::$$validation_message
- See
- class
Methods
\TINA_MVC\validate_max_value
Add your own validation classes by calling them 'validate_myrule' and declaring them in the TINA_MVC namespace. See the 'validate_required' for an example.
- Parent(s)
- \TINA_MVC\validate
Properties
$validation_message = ''
Your class should set this variable if your validation function fails
''
Details- Type
- n/a
- Inherited_from
- \TINA_MVC\validate::$$validation_message
- See
- class
Methods
\TINA_MVC\validate_min_length
Add your own validation classes by calling them 'validate_myrule' and declaring them in the TINA_MVC namespace. See the 'validate_required' for an example.
- Parent(s)
- \TINA_MVC\validate
Properties
$validation_message = ''
Your class should set this variable if your validation function fails
''
Details- Type
- n/a
- Inherited_from
- \TINA_MVC\validate::$$validation_message
- See
- class
Methods
\TINA_MVC\validate_min_value
Add your own validation classes by calling them 'validate_myrule' and declaring them in the TINA_MVC namespace. See the 'validate_required' for an example.
- Parent(s)
- \TINA_MVC\validate
Properties
$validation_message = ''
Your class should set this variable if your validation function fails
''
Details- Type
- n/a
- Inherited_from
- \TINA_MVC\validate::$$validation_message
- See
- class
Methods
\TINA_MVC\validate_recaptcha
You should not use this validation rule directly - it is added automatically by the form class
- Parent(s)
- \TINA_MVC\validate
Properties
$validation_message = ''
Your class should set this variable if your validation function fails
''
Details- Type
- n/a
- Inherited_from
- \TINA_MVC\validate::$$validation_message
- See
- class
Methods
\TINA_MVC\validate_regexp
Add your own validation classes by calling them 'validate_myrule' and declaring them in the TINA_MVC namespace. See the 'validate_required' for an example.
- Parent(s)
- \TINA_MVC\validate
Properties
$validation_message = ''
Your class should set this variable if your validation function fails
''
Details- Type
- n/a
- Inherited_from
- \TINA_MVC\validate::$$validation_message
- See
- class
Methods
\TINA_MVC\validate_required
Add your own validation classes by calling them 'validate_myrule' and declaring them in the TINA_MVC namespace. See the 'validate_required' for an example.
- Parent(s)
- \TINA_MVC\validate
Properties
$validation_message = ''
Your class should set this variable if your validation function fails
''
Details- Type
- n/a
- Inherited_from
- \TINA_MVC\validate::$$validation_message
- See
- class
Methods
\TINA_MVC\validate_sql_date
Add your own validation classes by calling them 'validate_myrule' and declaring them in the TINA_MVC namespace. See the 'validate_required' for an example.
- Parent(s)
- \TINA_MVC\validate
Properties
$validation_message = ''
Your class should set this variable if your validation function fails
''
Details- Type
- n/a
- Inherited_from
- \TINA_MVC\validate::$$validation_message
- See
- class
Methods
\TINA_MVC\validate_sql_datetime
Add your own validation classes by calling them 'validate_myrule' and declaring them in the TINA_MVC namespace. See the 'validate_required' for an example.
- Parent(s)
- \TINA_MVC\validate
Properties
$validation_message = ''
Your class should set this variable if your validation function fails
''
Details- Type
- n/a
- Inherited_from
- \TINA_MVC\validate::$$validation_message
- See
- class
Methods
\TINA_MVC\validate_sql_time
Add your own validation classes by calling them 'validate_myrule' and declaring them in the TINA_MVC namespace. See the 'validate_required' for an example.
- Parent(s)
- \TINA_MVC\validate
Properties
$validation_message = ''
Your class should set this variable if your validation function fails
''
Details- Type
- n/a
- Inherited_from
- \TINA_MVC\validate::$$validation_message
- See
- class