how to check if else in php when else part is run code example
Example 1: php if
<?php
if ($a > $b) {
echo "a is bigger than b";
$b = $a;
}
?>
Example 2: php if
<?php
if ($a > $b)
echo "a is bigger than b";
?>
<?php
if ($a > $b) {
echo "a is bigger than b";
$b = $a;
}
?>
<?php
if ($a > $b)
echo "a is bigger than b";
?>