summaryrefslogtreecommitdiff
path: root/lib/action.php
diff options
context:
space:
mode:
authorBrion Vibber <brion@pobox.com>2010-04-09 08:56:43 -0700
committerBrion Vibber <brion@pobox.com>2010-04-09 08:56:43 -0700
commita5cfc3954f807a6c31e67bd8c9a3ee353e250da0 (patch)
treed03ba6c367add6ea89e6f5d30cc50b6a6650291b /lib/action.php
parent1f8451f4aa9128e55d4b274faf7f0cd19d56e2b8 (diff)
Fix localization for license notice in page footer (for ticket #2274: i18n cleanup)
Diffstat (limited to 'lib/action.php')
-rw-r--r--lib/action.php18
1 files changed, 10 insertions, 8 deletions
diff --git a/lib/action.php b/lib/action.php
index 09113a598..0fc3a0dc4 100644
--- a/lib/action.php
+++ b/lib/action.php
@@ -845,14 +845,16 @@ class Action extends HTMLOutputter // lawsuit
'width' => '80',
'height' => '15'));
$this->text(' ');
- //TODO: This is dirty: i18n
- $this->text(_('All '.common_config('site', 'name').' content and data are available under the '));
- $this->element('a', array('class' => 'license',
- 'rel' => 'external license',
- 'href' => common_config('license', 'url')),
- common_config('license', 'title'));
- $this->text(' ');
- $this->text(_('license.'));
+ // TRANS: license message in footer. %1$s is the site name, %2$s is a link to the license URL, with a licence name set in configuration.
+ $notice = _('All %1$s content and data are available under the %2$s license.');
+ $link = "<a class=\"license\" rel=\"external license\" href=\"" .
+ htmlspecialchars(common_config('license', 'url')) .
+ "\">" .
+ htmlspecialchars(common_config('license', 'title')) .
+ "</a>";
+ $this->raw(sprintf(htmlspecialchars($notice),
+ htmlspecialchars(common_config('site', 'name')),
+ $link));
$this->elementEnd('p');
break;
}