Submitted by Kiran on Sun, 07/12/2009 - 22:25
Here I am listing a couple of Character Type functions, added to PHP in version 4.3.These functions test a given value against certain constraints for the current locale (established by the setlocale() function).
The Character Type functions provide validation specific to the given environment(i.e., the locale setting).
Function |
Checks If Value Contains |
| ctype_alnum() | Letters and numbers |
| ctype_alpha() | Letters only |
| ctype_cntrl() | Control characters |
| ctype_digit() | Numbers |
| ctype_graph() | Printable characters, except spaces |
| ctype_lower() | Lowercase letters |
| ctype_print() | Printable characters |
| ctype_punct() | Punctuation |
| ctype_space() | White space characters |
| ctype_upper() | Uppercase characters |
| ctype_xdigit() | Hexadecimal numbers |
»
- Kiran's blog
- 731 reads













Post new comment