Posted By

ajbatac on 01/19/08


Tagged

alpha validation numeric


Versions (?)

Who likes this?

2 people have marked this snippet as a favorite

iTony
bioascii


Alpha Numeric Testing


 / Published in: PHP
 

  1. function alpha_numeric($str)
  2. {
  3. return ( !preg_match("/^([-a-z0-9])+$/i", $str)) ? FALSE : TRUE;
  4. }

Report this snippet  

You need to login to post a comment.