diff --git a/bureau/class/functions.php b/bureau/class/functions.php index 9a47ad0c..8e694f07 100644 --- a/bureau/class/functions.php +++ b/bureau/class/functions.php @@ -578,6 +578,19 @@ function pager($offset,$count,$total,$url,$before="",$after="") { echo $after; } +function create_pass($length = 8){ + + $chars = "1234567890abcdefghijkmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ"; + $i = 0; + $password = ""; + while ($i <= $length) { + $password .= @$chars{mt_rand(0,strlen($chars))}; + $i++; + } + return $password; + +} + ?>