* John Nichel <[EMAIL PROTECTED]>:
> Diana Castillo wrote:
> > what kind of a function can I use that will tell me whether a variable is
> > alphanumeric (that is has only characters A-Z or 1-9 )?
>
> Something like this should work. (untested)
>
> preg_match ( "/^([a-z]||[A-Z]||[0-9])+$/", $stri
Philip Hallstrom wrote:
what kind of a function can I use that will tell me whether a variable is
alphanumeric (that is has only characters A-Z or 1-9 )?
http://us3.php.net/manual/en/function.ctype-alnum.php
bool ctype_alnum ( string text )
Checks if all of the characters in the provided string, t
what kind of a function can I use that will tell me whether a variable is
alphanumeric (that is has only characters A-Z or 1-9 )?
http://us3.php.net/manual/en/function.ctype-alnum.php
bool ctype_alnum ( string text )
Checks if all of the characters in the provided string, text, are
alphanumeric. I
Diana Castillo wrote:
what kind of a function can I use that will tell me whether a variable is
alphanumeric (that is has only characters A-Z or 1-9 )?
Something like this should work. (untested)
preg_match ( "/^([a-z]||[A-Z]||[0-9])+$/", $string )
--
John C. Nichel
ÜberGeek
KegWorks.com
716.85
[snip]
what kind of a function can I use that will tell me whether a variable
is
alphanumeric (that is has only characters A-Z or 1-9 )?
[/snip]
You can use a regular expression, start here http://us3.php.net/regex
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://w
5 matches
Mail list logo