Hello friends, let me explain, I make a query to get the scores when a user in 4 stages must acquire a number greater than 69 points, the idea is to show an image according to the score is greater or less than 69 points.
If the user does not achieve 69 points in the first stage, an image is displayed
$comp='<img src="img/icons/alert_graduate.gif" alt="">';
This same image should continue showing if even in the fourth stage this user can not get a score higher than 69 points
when the user achieves this score no matter what stage the image is displayed
$comp='<img src="img/icons/graduate.png" alt="">';
code:
if ($etapa1 > 69) {
$comp='<img src="img/icons/graduate.png" alt="">';
} elseif ($etapa2 > $etapa1) {
$comp='<img src="img/icons/graduate.png" alt="">';
} elseif ($etapa3 > $etapa1) {
$comp='<img src="img/icons/graduate.png" alt="">';
} elseif ($etapa4 > $etapa1) {
$comp='<img src="img/icons/graduate.png" alt="">';
} else{
$comp='<img src="img/icons/alert_graduate.gif" alt="">';
}