Can someone help me with an array problem?
| From: | Alex Behrens | Date: | Mon, 05 Jun 2000 02:25:00 +0000 |
| Subject: | Can someone help me with an array problem? | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-1010@lists.php.net to get a copy of this message | ||
Hi,
I'm rather new to PHP and I'm working on a very small script that just outputs a 9 value
random alphanumeric password to my browser.
What I have for the script now is listed every letter and number (62 in all) and then did 9 random
commands and had it output via HTML.
I would much rather create a single array and then do a rand command and loop.
Can someone help me through this.
I already have the array:
<?php
$alpha = array (
"letters" =>
array(a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u,v,w,x,y,z,A,B,C,D,E,F,G,H,I,J,K,L,M,N,O,P,Q,R,S,T,U,V,W,X,Y,Z),
"numbers" => array(1,2,3,4,5,6,7,8,9,0)
);
Thanks!
--------------------------------------------
-Alex "Big Al" Behrens
E-mail: bigal@3d-unlimited.com
Phone: 651-482-8779
Fax: 651-482-1391
ICQ: 3969599
Owner of the 3D-Unlimited Network:
http://www.3d-unlimited.com
Send News:
news@3d-unlimited.com