do not include special characters

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
kevin7
Forum Commoner
Posts: 96
Joined: Fri May 21, 2004 6:54 am

do not include special characters

Post by kevin7 »

how can i exclude some special characters...
for example... *%^&*(){}[]|?\/><"':;

i use it to validate username for a login...

tq..
User avatar
feyd
Neighborhood Spidermoddy
Posts: 31559
Joined: Mon Mar 29, 2004 3:24 pm
Location: Bothell, Washington, USA

Post by feyd »

I use [php_man]preg_match[/php_man], you might combo that with [php_man]preg_quote[/php_man]
Post Reply