Hierarchy fixup
[mirrors/Kyberia-bloodline.git] / wwwroot / inc / smarty / node_methodz / function.rand.php
diff --git a/wwwroot/inc/smarty/node_methodz/function.rand.php b/wwwroot/inc/smarty/node_methodz/function.rand.php
new file mode 100644 (file)
index 0000000..f03b3c7
--- /dev/null
@@ -0,0 +1,9 @@
+<?php
+function smarty_function_rand($params,&$smarty) {
+    if (is_numeric($params['min']) || is_numeric($params['max'])) {
+        $rand = rand($params['min'],$params['max']);
+    }
+    else $rand = rand();
+    $smarty->assign('rand',$rand);
+}
+?>
\ No newline at end of file
This page took 0.106034 seconds and 4 git commands to generate.