AAAAcom_chronoforms/form_actions/custom_serverside_validation/custom_serverside_validation.ctp 0000604 00000004426 15140257425 0037532 0 ustar 00 home/academiac/www/administrator/components
Header(array('settings' => 'Settings', 'help' => 'Help'), 'custom_serverside_validation_config_{n}'); ?>
tabStart('settings'); ?>
input('action_custom_serverside_validation_{n}_content1_config', array('type' => 'textarea', 'label' => "Code", 'rows' => 20, 'cols' => 70, 'smalldesc' => 'Returning "boolean" false will fail, anything else or no return at all will lead to success.')); ?>
tabEnd(); ?>
tabStart('help'); ?>
- You should use PHP code with php tags.
- Returning "boolean" false will fail, anything else or no return at all will lead to success.
- Set fields errors by adding a new key => value entry to the $form->validation_errors array, where "key" is the "field name" and "value" is the "Error message", for example, if you want to set an error to the "email" field you should use this code
$form->validation_errros['email'] = "Email error message is here.";.
tabEnd(); ?>