View Single Post
Old 03-08-2004, 09:47 PM  
mike503
Confirmed User
 
Industry Role:
Join Date: May 2002
Location: oregon.
Posts: 2,243
eregi("^[A-Za-z0-9_-]+$",$foo) is what i use.

so just change that to eregi_replace

$username = eregi_replace("^[A-Za-z0-9_-]+$","",$username)

i didn't like relying on \w or \W (and i think i had some problems with it)
__________________
php/mysql guru. hosting, coding, all that jazz.

Last edited by mike503; 03-08-2004 at 09:49 PM..
mike503 is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote