Hey there,
I have a form containing two elements (email, confirmation email). I've set a php validation on the confirmation email field. Code is following :
$jinput = JFactory::getApplication()->input;
$email = $jinput->get('mytablename___email', 'default value', 'string');
return $data == $email;
The validation is working : if the email adresses are the same, data is stored and I get the usual success message. When the two adresses are different, I have my error message (the one I set : the email adresses must match), but additionally I get this error :
Debug: Caught exception on php validation of mytablename ___check_email: syntax error, unexpected '!' in Unknown on line 21
The validation is the only php code i've set in that form.
What did I do wrong ?
Thanks and have a great day
I have a form containing two elements (email, confirmation email). I've set a php validation on the confirmation email field. Code is following :
$jinput = JFactory::getApplication()->input;
$email = $jinput->get('mytablename___email', 'default value', 'string');
return $data == $email;
The validation is working : if the email adresses are the same, data is stored and I get the usual success message. When the two adresses are different, I have my error message (the one I set : the email adresses must match), but additionally I get this error :
Debug: Caught exception on php validation of mytablename ___check_email: syntax error, unexpected '!' in Unknown on line 21
The validation is the only php code i've set in that form.
What did I do wrong ?
Thanks and have a great day