The IntlChar::charMirror() functionfind the “mirror-image” character from the entered character.
Syntax
IntlChar::charMirror(val)
Parameters
val − A character or integer value encoded as a UTF-8 string.
Return
The IntlChar::charMirror() function returns another Unicode code point that may serve as a mirror-image substitute, or codepoint itself if there is no such mapping or codepoint does not have the Bidi_Mirrored property.
Example
The following is an example −
<?php var_dump(IntlChar::charMirror("K")); echo "<br>"; var_dump(IntlChar::charMirror("*")); echo "<br>"; var_dump(IntlChar::charMirror("}")); echo "<br>"; var_dump(IntlChar::charMirror("[")); echo "<br>"; var_dump(IntlChar::charMirror("(")); echo "<br>"; ?>
Output
The following is the output −
string(1) "K" string(1) "*" string(1) "{" string(1) "]" string(1) ")"