Forums

Problem with custom validation

flashfs 02 Jun, 2017
I added this line on Validation Rules tab on a text input element:

validaCPF:CPF inválido


The, added this JS code on a Custom JS block:

jQuery.fn.form.settings.rules.validaCPF = function(value) {
  // my code
};


When submiting the form I get this error:

PHP Fatal error:  Call to undefined method G2\\L\\Validate::validaCPF() in /libraries/cegcore2/admin/extensions/chronofc/functions/validate_fields/validate_fields_output.php on line 61


First question: is it mandatory to have both JS and PHP validation?

I tried to create a PHP function just to pass this validation, but the error keeps showing.
Max_admin 02 Jun, 2017
Hi flash,

This is a bug, a fix should be available in the next update, you may also send me a message using the contact us page to get a patch file.

Best regards,
Max
Max
ChronoForms developer...
Did you try ChronoMyAdmin for managing your Joomla database tables ?
This topic is locked and no more replies can be posted.