From 970fc80c91e0bdfd355decf80b7bf0ed57d7fc9d Mon Sep 17 00:00:00 2001 From: Matthias Niess Date: Sun, 15 Apr 2018 21:44:57 +0200 Subject: [PATCH] Add note of the possibility to localize PasswordReset notifications I also added a complete example which might be a bit too much but should get people started more easily. --- passwords.md | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/passwords.md b/passwords.md index 114813a435..2224a4113f 100644 --- a/passwords.md +++ b/passwords.md @@ -95,3 +95,13 @@ You may easily modify the notification class used to send the password reset lin $this->notify(new ResetPasswordNotification($token)); } +If you want to localize the default notification you can simply add your translation strings to a [JSON file](/docs/{{version}}/localization#using-translation-strings-as-keys). A German localization would go into `resources/lang/de.json` and could look like this: + + { + "Hello!": "Hallo!", + "Regards": "Grüße", + "If you’re having trouble clicking the \":actionText\" button, copy and paste the URL below into your web browser: [:actionURL](:actionURL)": "Wenn du Probleme mit dem \":actionText\"-Button hast kopiere einfach diese Adresse in deinen Browser: [:actionURL](:actionURL)", + "You are receiving this email because we received a password reset request for your account.": "Du erhälst diese E-Mail weil bei uns eine Anfrage für die Rücksetzung deines Passworts eingegangen ist.", + "Reset Password": "Passwort zurücksetzen", + "If you did not request a password reset, no further action is required.": "Sollte die Anfrage nicht von dir stammen kannst du diese Mail ignorieren.", + }