X-Git-Url: https://jasonwoof.com/gitweb/?a=blobdiff_plain;f=session.php;h=f79373a5534788c3e3f1c96909e5773d15b8ebcd;hb=009661996a29825bae36d281c4b07ac55799d398;hp=901315770ab44afd73a8d7a85ad0bc2b883a599e;hpb=2b91af8c3f5c2b6cf3b749c769c5ccbe62890b5e;p=wfpl.git diff --git a/session.php b/session.php index 9013157..f79373a 100644 --- a/session.php +++ b/session.php @@ -36,15 +36,15 @@ # generate a new random 16-character string function session_generate_key() { $character_set = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789"; - $id = " "; + $id = " "; # PHP 4.2.0 and up seed the random number generator for you. # Lets hope that it seeds with something harder to guess than the clock. - for($i = 0; $i < 16; ++$i) { - $id{$i} = $character_set{mt_rand(0, 61)}; - } + for($i = 0; $i < 16; ++$i) { + $id{$i} = $character_set{mt_rand(0, 61)}; + } - return $id; + return $id; } # track this user with a session cookie (ie a cookie that goes away when the