PHP Character Functions

The functions provided by this extension check whether a character or string falls into a certain character class according to the current locale

Installation

Beginning with PHP 4.2.0 these functions are enabled by default. For older versions you have to configure and compile PHP with --enable-ctype. You can disable ctype support with --disable-ctype. Builtin support for ctype is available with PHP 4.3.0.

Runtime Configuration

This extension has no configuration directives defined in php.ini

PHP Ctype Functions List

Function Description
ctype_alnum() Check for alpha numeric character(s)
ctype_alpha() Check for alphabetic character(s)
ctype_cntrl() Check for control character(s)
ctype_digit() Check for numeric character(s)
ctype_graph() Check for any printable character(s) except space
ctype_lower() Check for lowercase character(s)
ctype_print() Check for printable character(s)
ctype_punct() Check for any printable character which is not whitespace or an alphanumeric character
ctype_space() Check for whitespace character(s)
ctype_upper() Check for uppercase character(s)
ctype_xdigit() Check for character(s) representing a hexadecimal digit

PHP Ctype Predefined Contstants

Ctype has no constants defined.

Subscribe to our Newsletter

Join our newsletter and get news in your inbox every week! We hate spam too, so no worries about this.

mail