From b27b574965ae49d9792af17083a8d271a4565ddb Mon Sep 17 00:00:00 2001 From: River Tarnell Date: Tue, 5 Jul 2005 05:18:17 +0000 Subject: [PATCH] bug 1651: ipboptions should be translatable --- includes/SpecialBlockip.php | 7 +++++-- languages/Language.php | 2 +- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/includes/SpecialBlockip.php b/includes/SpecialBlockip.php index 4d60cdc91b..98a4af2387 100644 --- a/includes/SpecialBlockip.php +++ b/includes/SpecialBlockip.php @@ -83,10 +83,13 @@ class IPBlockForm { $blockExpiryFormOptions = ""; foreach (explode(',', $scBlockExpiryOptions) as $option) { + list($show, $value) = explode(":", $option); + $show = htmlspecialchars($show); + $value = htmlspecialchars($value); $selected = ""; - if ($this->BlockExpiry === $option) + if ($this->BlockExpiry === $value) $selected = ' selected="selected"'; - $blockExpiryFormOptions .= "$option"; + $blockExpiryFormOptions .= ""; } $token = htmlspecialchars( $wgUser->editToken() ); diff --git a/languages/Language.php b/languages/Language.php index 5e0890d5e8..888f61c126 100644 --- a/languages/Language.php +++ b/languages/Language.php @@ -1405,7 +1405,7 @@ pages that were vandalized).", 'ipbreason' => 'Reason', 'ipbsubmit' => 'Block this user', 'ipbother' => 'Other time', -'ipboptions' => '2 hours,1 day,3 days,1 week,2 weeks,1 month,3 months,6 months,1 year,infinite', +'ipboptions' => '2 hours:2 hours,1 day:1 day,3 days:3 days,1 week:1 week,2 weeks:2 weeks,1 month:1 month,3 months:3 months,6 months:6 months,1 year:1 year,infinite:infinite', 'ipbotheroption' => 'other', 'badipaddress' => 'Invalid IP address', 'blockipsuccesssub' => 'Block succeeded', -- 2.20.1