summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFelix Dörre <felix@dogcraft.de>2014-06-11 00:20:43 +0200
committerFelix Dörre <felix@dogcraft.de>2014-06-11 00:25:14 +0200
commitf3885b3bc9ff61da78fb541151f16b0ecfdf62eb (patch)
treeb674f197a4ca5b264c302e3f9998ff5b5a4faaa3
parent2affa9c6e9a1f2a7f68ab5fa306374cd037d6227 (diff)
downloadcacert-devel-f3885b3bc9ff61da78fb541151f16b0ecfdf62eb.tar.gz
cacert-devel-f3885b3bc9ff61da78fb541151f16b0ecfdf62eb.tar.xz
cacert-devel-f3885b3bc9ff61da78fb541151f16b0ecfdf62eb.zip
bug-1280: Parse the language code from the locale.
Splitting the string at "_" and lowering the characters.
-rw-r--r--pages/wot/9.php6
1 files changed, 5 insertions, 1 deletions
diff --git a/pages/wot/9.php b/pages/wot/9.php
index a8b9413..94523f2 100644
--- a/pages/wot/9.php
+++ b/pages/wot/9.php
@@ -49,7 +49,11 @@
<? if($userlang != "") { ?>
<tr>
<td class="DataTD"><?=_("Language")?>:</td>
- <td class="DataTD" align="left"><? printf(_("%s prefers to be contacted in %s"), sanitizeHTML($user['fname']), L10n::$translations[$userlang]) ?></td>
+ <?
+ $parts = explode("_", $userlang ,2);
+ $printlang = strtolower($parts[0]);
+ ?>
+ <td class="DataTD" align="left"><? printf(_("%s prefers to be contacted in %s"), sanitizeHTML($user['fname']), L10n::$translations[$printlang]) ?></td>
</tr>
<? } ?>
<?