How can PHP handle case-sensitive comparisons when using strpos or stripos functions?

When using the strpos or stripos functions in PHP for string comparisons, it's important to note that these functions are case-sensitive by default. To handle case-insensitive comparisons, you can use the stripos function instead of strpos. This function performs a case-insensitive search for the specified substring within a string.

$string = "Hello, World!";
$substring = "hello";

if (stripos($string, $substring) !== false) {
    echo "Substring found!";
} else {
    echo "Substring not found.";
}