diff options
Diffstat (limited to 'Wrapper/Functions/func_language.php')
| -rw-r--r-- | Wrapper/Functions/func_language.php | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/Wrapper/Functions/func_language.php b/Wrapper/Functions/func_language.php new file mode 100644 index 0000000..ae54da0 --- /dev/null +++ b/Wrapper/Functions/func_language.php @@ -0,0 +1,16 @@ +<?php +// **************************************************************************** +// Description: Modification de la variable lang de la session +// qui sert à définir quel dossier de language importer +// **************************************************************************** +function set_language($language) { + $_SESSION["lang"] = $language; + // Redirection vers la page actuelle avec la langue à affiche. + if ($_SESSION["src"] == "index") { + header("Location: /".$_SESSION["src"].".php"); + } else { + header("Location: /Views/".$_SESSION["src"].".php"); + } + die(); +} +?>
\ No newline at end of file |
