BTW, This is one of the functions I use you might find it helpful in trimming down your function.
function gen_password($length = 8) { $chars = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789"; for($i = 0; $i < $length; $i++) { $x = rand(0, strlen($chars) -1); $password .= $chars{$x}; } return $password; } > Hope this helps - I also hope anybody else is fairly gentle with their criticisms > and pointers to whatever is wrong with the script - this is the first time I've > ventured to include something like this in a response to an email on the list :-( > Peer review is the best way we can improve our programming. It is good to post code so that we can all get a better understanding of better techniques and tricks. Regards, AW -- Abdul-Wahid Paterson Lintrix Networking & Communications ltd. Web: http://www.lintrix.net/ Tel: +44 7801 070621 Email/Jabber: [EMAIL PROTECTED] -------------------------------------------------------------------- Web-Hosting | Development | Security | Consultancy | Domains --------------------------------------------------------------------
signature.asc
Description: This is a digitally signed message part