I use a javascript to do that for my forms:

if (window.RegExp) {
  var reg = new RegExp("^[_0-9a-z]*$","gi");
  if (!reg.test(f.elements['username'].value)) {
    alert("Kullanici adi harf ve/veya rakamlardan
olusmalidir. Lutfen Duzeltiniz!");
    f.elements['username'].focus();
    return(false);
  }
}

I am sure you could write something similar with PHP.....

--- Brandon Orther <[EMAIL PROTECTED]> wrote:
> Hello,
>  
> I am looking for a way to check a string if it has
> anything other than
> Numbers or Letters.  Does anyone know how to do this?
> Thank you,
> 
> --------------------------------------------
> Brandon Orther
> WebIntellects Design/Development Manager
> [EMAIL PROTECTED]
> 800-994-6364
> www.webintellects.com
> --------------------------------------------  
>  
> 


=====
Mehmet Erisen
http://www.erisen.com

__________________________________________________
Do You Yahoo!?
Make international calls for as low as $.04/minute with Yahoo! Messenger
http://phonecard.yahoo.com/

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]

Reply via email to