From 164a7ab020d1f11632f2d76d72a13ec01cd9f2cd Mon Sep 17 00:00:00 2001 From: Thegennok Date: Sun, 15 Nov 2020 20:33:35 +0100 Subject: [PATCH] Missing modifier --- .../smarty/plugins/modifier.temps.php | 29 +++++++++++++++++++ 1 file changed, 29 insertions(+) create mode 100644 onyx2/modules/templates/smarty/plugins/modifier.temps.php diff --git a/onyx2/modules/templates/smarty/plugins/modifier.temps.php b/onyx2/modules/templates/smarty/plugins/modifier.temps.php new file mode 100644 index 0000000..4d827de --- /dev/null +++ b/onyx2/modules/templates/smarty/plugins/modifier.temps.php @@ -0,0 +1,29 @@ + + * Name: temps
+ * Date: Nov 15, 2020 + * Purpose: Affiche un temps à partir d'un nombre de seconde + * Example: {$nombre_de_secondes|temps} + * @version 1.0 + * @author Nigel + * @param int + * @return string + */ +function smarty_modifier_temps($secondes) +{ + return gmdate("H:i:s", $secondes); +} + +/* vim: set expandtab: */ + +?>