Thanks once again NogDog. I haven't checked the code, but I can see that it might suite me well. However, same problem might arise as by looking at this code. In the preg_match part where you specify "preg_match('/[0-9].*[0-9]/', $_POST['user_name'])" I know that I can add {2,} to indicate how many digits I want, but the initial problem arises that these digits have to be consequent or code will error out (or am I wrong?). For instance if the user wants its name to be "Bob2Smith2" it does contain two digits but the regression won't see it this way, for these two digits are not together. I have tried using "preg_match_all()" without luck. Any further suggestions. Thanks again!