Re: HN CAPTCHA at http://www.phpclasses.org

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Quoting Kim Christensen <kim.christensen@xxxxxxxxx>:


> To solve your problem, replace the generate_private() function in
> hn_captcha.class.php - starting at row 756 - with this code:
> 
>    function generate_private($public="")
>    {
>       $letters = "1234567890abcdefghijklmnopqrstuvwxyz";
>       $maxsize = strlen($letters)-1;
>       for($i=0;$i<6;$i++){
>             $rstring .= $letters{mt_rand(0, $maxsize)};
>       }
>       return $rstring;
>    }
> 
> This should yield a 6 char "random" string containing digits 0-9 and
> letters a-z.
> 
> Good luck!
> 
> --
> Kim Christensen
> kim.christensen@xxxxxxxxx
> 


Thank you Kim.

--roger


---------------------------------------------------
Sign Up for free Email at http://ureg.home.net.my/
---------------------------------------------------

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux