I am trying to change the label for Craft's form errors. My site local is currently fr_CA, and when I try to submit a form with an error, the error message returned is in french, but the label of the field is in english.
I have managed to translate field labels for plugins, such as the Contact Form plugin by P&T, without any issues by using static translations. All I simply did was create a file with the plugin translation category as a name such as 'contact-form.php' and it works flawlessly.
However, with the forms included in Craft, it doesn't seem to work. For example, with the user registration form, if I submit it without a password, it will come up with an error saying the password needs to have at least 6 characters. Here is the message I receive :
New Password doit comporter au moins 6 caractères.
The 'New Password' is in english while the rest of the message is in french.
If I try to create a file called 'site.php' or 'app.php' in the translations folder under the right locale, it doesn't translate the 'New Password'. Here is the content of the file :
<?php return [ 'New Password' => 'Nouveau mot de passe' ];
It's like none of the translations supplied to Craft are being recognized. Has anyone run into this problem or have a solution?