Source Code:
(back to article)
<?php $str1 = "apple"; $str2 = "orange"; $result = strcoll($str1, $str2); if ($result == 0) { echo "The two strings are equal"; } elseif ($result < 0) { echo "The first string is less than the second string"; } else { echo "The first string is greater than the second string"; }
Result:
Report an issue