diff options
author | Phil Davis <phil.davis@inf.org> | 2016-01-15 23:23:02 +0545 |
---|---|---|
committer | Phil Davis <phil.davis@inf.org> | 2016-01-15 23:23:02 +0545 |
commit | 31ac02d40dd658d2a8f7ffc2bfbf22eb5b3ba9e0 (patch) | |
tree | b5c51e7e5d858403b2be1f387c358e48ef6c66aa /src/usr/local/www/diag_confbak.php | |
parent | 0b204e240b77da28a269cf0e87826bb35ebee542 (diff) | |
download | pfsense-31ac02d40dd658d2a8f7ffc2bfbf22eb5b3ba9e0.zip pfsense-31ac02d40dd658d2a8f7ffc2bfbf22eb5b3ba9e0.tar.gz |
diag_confbak make a single gettext
Sentences that are constructed in pieces like this are a potential problem for translation, if the target language needs to use a different grammatical word order. e.g. in Nepali we would say datetime-dekhi datetime-samma (datetime-from datetime-to).
Organize it into a single gettext() that has the whole sentence in one go with numbering of the parameters so they can also be potentially re-ordered as needed in a translation.
I am having a look at a few places where the gettext() translation is missing, and noticed this kind of thing also. When I see this sort of sentence construction using sentence fragments built up with multiple gettext() calls I will fix them up like this and make PRs.
Diffstat (limited to 'src/usr/local/www/diag_confbak.php')
-rw-r--r-- | src/usr/local/www/diag_confbak.php | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/usr/local/www/diag_confbak.php b/src/usr/local/www/diag_confbak.php index 142a9ad..2ada62c 100644 --- a/src/usr/local/www/diag_confbak.php +++ b/src/usr/local/www/diag_confbak.php @@ -149,7 +149,7 @@ if ($diff) { <div class="panel panel-default"> <div class="panel-heading"> <h2 class="panel-title"> - <?=gettext("Configuration diff from ")?><?=date(gettext("n/j/y H:i:s"), $oldtime); ?><?=gettext(" to ")?><?=date(gettext("n/j/y H:i:s"), $newtime); ?> + <?=sprintf(gettext('Configuration diff from %1$s to %2$s'), date(gettext("n/j/y H:i:s"), $oldtime), date(gettext("n/j/y H:i:s"), $newtime))?> </h2> </div> <div class="panel-body table-responsive"> |