Re: Problem in a generate password function

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

 



At 12:20 PM -0700 3/31/08, Jim Lucas wrote:
I have a very similar routine, but for the previous line, since you can reference a string as an array, I do this:

$char = $possible[mt_rand(0, strlen($possible)-1)];

In this example, it would save ten function calls, if not more.

just a suggestion

Neat -- thanks,

tedd

--
-------
http://sperling.com  http://ancientstones.com  http://earthstones.com

--
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