Hello all community again !
I only want to know what is faster and better (logical, not writing or tabbing) between:
IF...ELSE...IF...ELSE...
IF...ELSEIF...ELSEIF...ELSE...
For example:
$i=0;
if($i>5){
echo '$i is greater than 5.';
}else{
if($i>0){
echo '$i is greater than 0 but less than 6.';
}else{
echo '$i is equal to 0.';
}
}
OR
$i=0;
if($i>5){
echo '$i is greater than 5.';
}elseif($i>0){
echo '$i is greater than 0 but less than 6.';
}else{
echo '$i is equal to 0.';
}
Thanks all !