$result
will never be null. You need to check for something like number of rows –
$row_cnt = mysqli_num_rows($result);
If that is greater than 0, then go to your else.
9
solved PHP code always shows wrong result
$result
will never be null. You need to check for something like number of rows –
$row_cnt = mysqli_num_rows($result);
If that is greater than 0, then go to your else.
9
solved PHP code always shows wrong result