kohana validation rule versus language file
i have a kohana powered website and i use a language file for language messages. in the model i do validation, and i have a 'matches' rule. here is one:
->rule('email2', 'matches', array('email');
and in the languge file i do:
'email2.matches' => 'message here.',
but i get the error message: E-mail: must be the same as E-mail: instead of 'message here.'.
where i am wrong? is this thing documented ?
thanks a lot!
Validation errors use messages, which are separate from i18n. You will need to make your own messages/validation.php, and include
<?php return array( 'email2' => array( 'matches' => 'Message here', ), );