-
I am trying to customize localization messages in Password rules. but, I think password validation error messages only support English. How to change error messages to other languages without framework/src/Illuminate/Validation/Rules/Password.php Lines 305 to 319 in 78cb588 |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 2 replies
-
Hi @pronist I was just struggling with this as well. I found the answer in this post: https://www.magutti.com/blog/laravel-8-password-rule. You have to create a .json file like "en.json" or whatever your localization is, in your lang folder. Eg:
This must contain the following: {
"The :attribute must contain at least one uppercase and one lowercase letter.": "Your translation",
"The :attribute must contain at least one letter.": "Your translation",
"The :attribute must contain at least one symbol.": "Your translation"
} I hope this helps :) |
Beta Was this translation helpful? Give feedback.
-
@Nielson Excellent! It works for me. |
Beta Was this translation helpful? Give feedback.
Hi @pronist
I was just struggling with this as well. I found the answer in this post: https://www.magutti.com/blog/laravel-8-password-rule.
You have to create a .json file like "en.json" or whatever your localization is, in your lang folder.
Eg:
This must contain the following:
I hope this helps :)