mirror of
https://gitlab.easter-eggs.com/ee/ldapsaisie.git
synced 2024-11-18 00:09:06 +01:00
- functions : fonction tr() ajout du support de la traduction d'une simple chaîne.
This commit is contained in:
parent
d8975aff0b
commit
8fe237627c
1 changed files with 2 additions and 0 deletions
|
@ -431,6 +431,8 @@ function LSdebugDefined() {
|
|||
|
||||
function tr($msg,$key=null) {
|
||||
$val = $GLOBALS['Smarty']->get_template_vars($msg);
|
||||
if (!$val)
|
||||
$val=$msg;
|
||||
if (is_array($val)) {
|
||||
echo __($val[$key]);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue