-
What will be the output of the following PHP code ?
<?php
function Condition($number)
{
if ($number == 3)
echo "Condition 3rd executed....";
if ($number == 7)
echo "Condition 7th executed....";
if ($number == 8)
echo "Condition 8th executed....";
if ($number == 19)
echo "Condition 19th executed....";
}
$var = stripos("I know the php, And I love to know php!","the");
Condition($var);
?>
-
- Condition 3rd executed....
- Condition 7th executed....
- Condition 8th executed....
- Condition 19th executed....
- None of these
Correct Option: B
The stripos() function finds the position of the first occurrence of a string inside another string. In this case it returns 7.