log in problem
Moderator: General Moderators
log in problem
I make login system and I want to verifying that username can't use blank space or "/" and other symbol. how to solve this problem?? thanks very much
- John Cartwright
- Site Admin
- Posts: 11470
- Joined: Tue Dec 23, 2003 2:10 am
- Location: Toronto
- Contact:
ctype_alpha() && strlen() is what I would use
I'd go the regex route with preg_match()
something like this maybe?
untested:
something like this maybe?
untested:
Code: Select all
$pattern = "/(\/|\s+)/";