Re: [PHP] Arrays as pointers?

2002-01-24 Thread Erik Price
I could be wrong about this, but here goes: Strings are in fact arrays. An array of characters. The code your friend gave you manipulates this array in the same way that it would any "normal" array. The only problem (not really a problem even) is that when dealing with character-based arra

Re: [PHP] Arrays as pointers?

2002-01-24 Thread Mike Frazer
:[EMAIL PROTECTED]] > Sent: Friday, January 25, 2002 8:57 AM > To: PHP List > Subject: [PHP] Arrays as pointers? > > > A friend of mine showed me this code recently. > > function firstLogin_string() { > mt_srand(make_seed()); > $pool = "AaBbCcDdEeFfGgHhIiJjK

Re: [PHP] Arrays as pointers?

2002-01-24 Thread DL Neil
v0idnull, [surely you don't think of yourself as a nonentity twice over?] > A friend of mine showed me this code recently. > > function firstLogin_string() { > mt_srand(make_seed()); > $pool = "AaBbCcDdEeFfGgHhIiJjKkLlM"; > $length = 26; > for($i=0; $i < $length; $i++) { > $key .= $pool[mt_ran

RE: [PHP] Arrays as pointers?

2002-01-24 Thread Martin Towell
ssage- From: v0idnull [mailto:[EMAIL PROTECTED]] Sent: Friday, January 25, 2002 8:57 AM To: PHP List Subject: [PHP] Arrays as pointers? A friend of mine showed me this code recently. function firstLogin_string() { mt_srand(make_seed()); $pool = "AaBbCcDdEeFfGgHhIiJjKkLlM&qu

[PHP] Arrays as pointers?

2002-01-24 Thread v0idnull
A friend of mine showed me this code recently. function firstLogin_string() { mt_srand(make_seed()); $pool = "AaBbCcDdEeFfGgHhIiJjKkLlM"; $length = 26; for($i=0; $i < $length; $i++) { $key .= $pool[mt_rand(0,strlen($pool)-1)]; } retu