mirror of
https://github.com/vrana/adminer.git
synced 2025-08-13 18:14:07 +02:00
Use vsprintf()
git-svn-id: https://adminer.svn.sourceforge.net/svnroot/adminer/trunk@241 7c3ca157-0c34-0410-bff1-cbf682f78f5c
This commit is contained in:
@@ -161,7 +161,6 @@ function lang($idf, $number = null) {
|
||||
if ($number === false) { // used in _compile.php
|
||||
return ($translation ? $translation : $idf);
|
||||
}
|
||||
$args = func_get_args();
|
||||
if (is_array($translation) && $translation) {
|
||||
switch ($LANG) {
|
||||
case 'cs': $pos = ($number == 1 ? 0 : (!$number || $number >= 5 ? 2 : 1)); break;
|
||||
@@ -169,10 +168,9 @@ function lang($idf, $number = null) {
|
||||
}
|
||||
$translation = $translation[$pos];
|
||||
}
|
||||
if ($translation) {
|
||||
$args[0] = $translation;
|
||||
}
|
||||
return call_user_func_array('sprintf', $args);
|
||||
$args = func_get_args();
|
||||
array_shift($args);
|
||||
return vsprintf(($translation ? $translation : $idf), $args);
|
||||
}
|
||||
|
||||
function switch_lang() {
|
||||
|
Reference in New Issue
Block a user