PHP | IntlChar::totitle() Function Last Updated : 12 Feb, 2021 Comments Improve Suggest changes Like Article Like Report The IntlChar::totitle() function is an inbuilt function in PHP which is used to check whether the input code point is a Unicode character titlecase or not.Syntax: mixed IntlChar::totitle( $codepoint ) Parameters: This function accepts a single parameter $codepoint which is mandatory. The $codepoint parameter is a character or integer value, which is encoded as a UTF-8 string.Return Value: Returns the simple_Titlecase_Mapping of the code point, if any; otherwise the code point itself. The return type will be an integer unless the code point was passed as a UTF-8 string, in which case a string will be returned.Below programs illustrate the IntlChar::totitle() Function in PHP:Program 1: php <?php // PHP function to illustrate the // use of IntlChar::totitle() // Input Capital letter codepoint var_dump(IntlChar::totitle("G")); // Input Capital letter codepoint var_dump(IntlChar::totitle("g")); // Input Capital letter codepoint var_dump(IntlChar::totitle("a")); // Input int char an identifier // of codepoint value var_dump(IntlChar::totitle("\u{00A0}")); // Input symbolic space codepoint value var_dump(IntlChar::totitle(" ")); // Input symbolic codepoint value var_dump(IntlChar::totitle(" ^ ")); // Input int codepoint value var_dump(IntlChar::totitle("9")); // Input control character codepoint value var_dump(IntlChar::totitle("\n")); // Input character value // return its ASCII value var_dump(IntlChar::totitle(ord("D"))); var_dump(IntlChar::totitle(ord("d"))); // Input ASCII value 0054 is "T" var_dump(IntlChar::totitle(ord("0054"))); var_dump(IntlChar::totitle(ord("@"))); ?> Output: string(1) "G" string(1) "G" string(1) "A" string(2) " " string(1) " " NULL string(1) "9" string(1) " " int(68) int(68) int(48) int(64) Program 2: php <?php // PHP function to illustrate the // use of IntlChar::totitle() // Declare an array with // different codepoint value $arr = array("X", "x", "*", "8", "0", " ", ); // For loop condition to check // each character through function foreach ($arr as $val) { // Check each element as code point data var_dump(IntlChar::totitle($val)); } ?> Output: string(1) "X" string(1) "X" string(1) "*" string(1) "8" string(1) "0" string(1) " " Related Articles: IntlChar::isspace() FunctionIntlChar::isIDIgnorable() FunctionIntlChar::isIDStart() FunctionIntlChar::isIDPart() Function Reference: http://php.net/manual/en/intlchar.totitle.php Comment More infoAdvertise with us Next Article PHP | IntlChar::totitle() Function jit_t Follow Improve Article Tags : Web Technologies PHP PHP-array PHP-Intl Similar Reads PHP | IntlChar tolower() Function The IntlChar::tolower() function is an inbuilt function in PHP which is used to convert the character into Unicode lowercase character. The given input character is mapped to its lowercase character equivalent. If the character has no lowercase equivalent then it returns the character itself. Syntax 2 min read PHP | IntlChar toupper() Function The IntlChar::toupper() function is an inbuilt function in PHP which is used to convert the character into Unicode character uppercase. The given character is change with its uppercase equivalent character. If the character has no uppercase equivalent then it returns the same character. Syntax: mixe 2 min read PHP | IntlCalendar toDateTime() Function The IntlCalendar::toDateTime() function is an inbuilt function in PHP which is used to convert an IntlCalendar object into a DateTime object. The DateTime object represents upto second precision with error round less than 1 second. Syntax: Object oriented styleDateTime IntlCalendar::toDateTime( void 1 min read PHP | IntlChar istitle() Function The IntlChar::istitle function is an inbuilt function in PHP which is used to check whether the input character code point is a titlecase letter or not. In True cases, the characters with the general category are "Lt" (titlecase letter).Syntax: bool IntlChar::istitle( $codepoint ) Parameters: This f 2 min read PHP | IntlChar::chr() Function The IntlChar::chr() function is an inbuilt function in PHP which is used to check whether the given input character is Unicode code point value or not. It returns Unicode character by code point value.Syntax: string IntlChar::chr( $codepoint ) Parameters: This function accepts a single parameter $co 2 min read PHP IntlChar::ord() Function The IntlChar::ord() function is an inbuilt function in PHP which is used to return the Unicode code point value of the given character. Syntax: int IntlChar::ord( $character ) Parameters: This function accepts a single parameter $character which is mandatory. This parameter is a Unicode character. R 2 min read PHP | IntlCalendar set() Function The IntlCalendar::set() function is an inbuilt function in PHP which is used to set the time field or several common fields at once. The range of field value depends on the calendar. This function can not be called with exactly four parameters. Syntax: Object oriented style bool IntlCalendar::set( i 2 min read PHP | IntlChar digit() function The IntlChar::digit() function is an inbuilt function in PHP which is used to get the decimal digit value of a code point for a given radix. This function returns the decimal digit value of the code point in the specified radix. Syntax: int IntlChar::digit( $codepoint, $radix ) Parameters: This func 2 min read PHP IntlChar::isbase() Function PHP IntlChar::isbase() function is an inbuilt function in PHP that is used to check whether the given input data is a base character or not. If the specified code point is a base character then it returns TRUE for general categories "L" (Letters), "N" (numbers), "Mc" (spacing combining marks), and " 2 min read PHP token_name() Function The token_name() function is an inbuilt function in PHP that is used to retrieve the textual representation of a given token identifier. In PHP, when you write code, it gets parsed into a series of tokens, which are the basic units of code that the interpreter understands. These tokens include keywo 1 min read Like