From ee5fae3aae71fb07fb13a135262e500e022ca94e Mon Sep 17 00:00:00 2001 From: HB9HIL Date: Mon, 28 Oct 2024 08:30:02 +0000 Subject: [PATCH] make emails translatable --- .../views/email/admin_reset_password.php | 15 +++++++-------- application/views/email/forgot_password.php | 14 +++++++------- application/views/email/oqrs_request.php | 19 +++++++++++-------- application/views/email/testmail.php | 5 +++-- 4 files changed, 28 insertions(+), 25 deletions(-) diff --git a/application/views/email/admin_reset_password.php b/application/views/email/admin_reset_password.php index 7de2ffbc6..0a49105a0 100644 --- a/application/views/email/admin_reset_password.php +++ b/application/views/email/admin_reset_password.php @@ -1,16 +1,15 @@ -Hello + +sprintf("Your username is: %s", '' . $user_name . ''); +sprintf(__("Click here to reset your password: %s"), site_url('user/reset_password/') . $reset_code); -Click here to reset your password: - - -If you didn't request any password reset, just ignore this email and talk to an admin of your Wavelog instance. +__("If you didn't request any password reset, just ignore this email and talk to an admin of your Wavelog instance. Regards, -Wavelog +Wavelog"); diff --git a/application/views/email/forgot_password.php b/application/views/email/forgot_password.php index 4e7414664..1f69cf647 100644 --- a/application/views/email/forgot_password.php +++ b/application/views/email/forgot_password.php @@ -1,15 +1,15 @@ -Hi, + +You or someone else has requested a password reset on your Wavelog account."); +sprintf(__("Your password reset code is: %s"), $reset_code); -Click here to reset password +sprintf(__("Click here to reset your password: %s"), site_url('user/reset_password/') . $reset_code); - -If you didn't request this just ignore. +__("If you didn't request this just ignore. Regards, -Wavelog \ No newline at end of file +Wavelog"); \ No newline at end of file diff --git a/application/views/email/oqrs_request.php b/application/views/email/oqrs_request.php index 8c1b92c14..7a41e94f5 100644 --- a/application/views/email/oqrs_request.php +++ b/application/views/email/oqrs_request.php @@ -1,14 +1,17 @@ -Hi, +. - -The user entered the following message: +sprintf( __("Hi, - - +You got an OQRS request from %s."), strtoupper($callsign)); -Please log into your Wavelog and process it. +if ($usermessage != "") { +__("The user entered the following message: + +%s", $usermessage); +} + +__("Please log into your Wavelog and process it. Regards, -Wavelog +Wavelog"); diff --git a/application/views/email/testmail.php b/application/views/email/testmail.php index 70bf8e60c..2a87153fa 100644 --- a/application/views/email/testmail.php +++ b/application/views/email/testmail.php @@ -1,4 +1,5 @@ -Hi, +