Forums

EventSwitcher

caratti 05 May, 2014
I am using EventSwitcher to validate fields (checksum and other rules).
When no erros is found by my php code the form works fine (event success). However, if an error is identified by my php code, no error message is shown (event fail).

Exemple:

if ($result->qtd >= 1) {
$form->validation_errors['usuario'] = 'My error message!';
return 'fail';
}

How can I show the erro 'My error message!' and other errors and also reload the form?

Ricardo.
Max_admin 05 May, 2014
Answer
Hi Ricardo,

Instead of using "$form->validation_errors", please use "$form->errors" in v5

Regards,
Max
Max, ChronoForms developer
ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
caratti 05 May, 2014
Thanks Max,
it is working now.

Ricardo.
This topic is locked and no more replies can be posted.