int ord
Returns the ASCII value of the first character of string. This function complements chr().
Example 1. Ord() example
1 2 if (ord ($str) == 10) { 3 echo "The first character of \$str is a line feed.\n"; 4 } 5
See also chr().