PHP | IntlChar hasBinaryProperty() function Last Updated : 27 Aug, 2019 Comments Improve Suggest changes Like Article Like Report The IntlChar::hasBinaryProperty() function is an inbuilt function in PHP which is used to checks a binary Unicode property for a code point. Syntax: bool IntlChar::hasBinaryProperty( $codepoint, $property ) Parameters: This function accepts two parameters as mentioned above and described below: $codepoint: The $codepoint value is an integer values or character, which is encoded as a UTF-8 string. $property: This stores the IntlChar::PROPERTY_* constants. Return Value: This function returns boolean value (true or false) based on binary Unicode property. Below programs illustrate the IntlChar::hasBinaryProperty() function in PHP: Program 1: php <?php // PHP function to illustrate the use of // IntlChar::hasBinaryProperty() function // Input data is character type var_dump(IntlChar::hasBinaryProperty("G", IntlChar::PROPERTY_ALPHABETIC)); // Input data is string type var_dump(IntlChar::hasBinaryProperty("Geeks", IntlChar::PROPERTY_ALPHABETIC)); // Input data is mirrored bracket character type var_dump(IntlChar::hasBinaryProperty("}", IntlChar::PROPERTY_BIDI_MIRRORED)); // Input data is character type var_dump(IntlChar::hasBinaryProperty("%", IntlChar::PROPERTY_BIDI_MIRRORED)); ?> Output: bool(true) NULL bool(true) bool(false) Program 2: php <?php // PHP function to illustrate the use of // IntlChar::hasBinaryProperty() function // Declare an array $arr $arr = array("A", "{", "^", ")", "6", "Geeks", "))"); // Loop run for every array element foreach ($arr as $val){ // Check each element as code point data var_dump(IntlChar::hasBinaryProperty($val, IntlChar::PROPERTY_BIDI_MIRRORED)); } ?> Output: bool(false) bool(true) bool(false) bool(true) bool(false) NULL NULL Reference: https://www.php.net/manual/en/intlchar.hasbinaryproperty.php Comment More infoAdvertise with us Next Article PHP | IntlChar hasBinaryProperty() function R R_Raj Follow Improve Article Tags : Web Technologies PHP PHP-function PHP-Intl Similar Reads PHP | IntlChar getIntPropertyValue() Function The IntlChar::getIntPropertyValue() function is an inbuilt function in PHP which is used to get the value for Unicode property for a code point.Syntax: int IntlChar::getIntPropertyValue( $codepoint, $property ) Parameter: This function accepts two parameters as mentioned above and described below: $ 2 min read PHP | IntlChar getPropertyEnum() Function The IntlChar::getPropertyEnum() function is an inbuilt function in PHP which is used to get the property constant value for a given property name. The property name is going to be specified in PropertyAliases.txt, which is a Unicode Database file. All types of variants are recognized in this, be it 2 min read PHP | IntlChar getPropertyName() Function The IntlChar::getPropertyName() function is an inbuilt function in PHP which is used to get the Unicode name for a given property which is given in the Unicode database file PropertyAliases.txt. This function maps the property IntlChar::PROPERTY_GENERAL_CATEGORY_MASK to the synthetic names "gcm" / " 2 min read PHP | IntlChar getIntPropertyMinValue() Function The IntlChar::getIntPropertyMinValue() function is an inbuilt function in PHP which is used to get the minimum value for a Unicode property. This could be used to access the information as well as manipulating the Unicode characters. For an enumerated/integer/binary Unicode property, this is going t 1 min read PHP | IntlChar getIntPropertyMaxValue() Function The IntlChar::getIntPropertyMaxValue() function is an inbuilt function in PHP which is used to get the maximum value for a Unicode property. This could be used to access the information as well as manipulating the Unicode character. For an enumerated/integer/binary Unicode property, this is going to 1 min read Like