chr() function in php
0 1894
PHP chr() function is used to returns characters corresponding to given ASCII values. It is an inbuilt function of PHP. The return type of this function is character means it returns characters.
Syntax:
chr($ascii_code);
here,
$ascii_code represents an ASCII value.
Example:
<?php echo chr(96) . "<br>"; // return single quote echo chr(040) . "<br>"; // return whitespace echo chr(47) . "<br>"; // return division ?>
Output:
Share:
Comments
Waiting for your comments