This is an excellent go, and I'll only make one kibbitz technically: \_ $randigit = int( rand( $base) ); Do you trust rand() to be random? It's probably mostly random as far as humans can tell, but computers? rand('maybe', 'maybe not'). :-) David