Just looking for some pointers when testing a users input to a registration form.
Getting a username
password (twice)
name
address
postcode
e-mail
Date of birth
At the moment I'm checking that each isn't empty, has been filled in, dosn't exceed the length in the database, that the username (convert it to lowercase first) and e-mail aren't already in the system, that the two password entries match.
Is there anyway to ensure that what has been entered is a number only?
Also what about the date of birth, is there a way I can make sure what is entered is a valid date?
I'm just running this on a localhost at the moment so I'm not sending e-mails and having the user validate their registration via a link in the main, but is there anyway to check that the e-mail is in a valid format eg name@domain.com
Thanks if you can help out. Much appreciated.