I'm trying to create a style to show it if the field is 1 or 0
When it's 1 and 0 it shows me well, the thing is that if I'm wrong and I want it appear the red style the green still appears.
<?php if($resultado['id_usuario_autoriza']): ?>
<tr>
<?php if($resultado['autorizado']): ?>
<th style="color:green;">Autorizado Por:</th>
<td style="color:green;"><?=$resultado_usuario_autoriza['personaNombre']?> <?=$resultado_usuario_autoriza['apellido']?><?php if ($resultado_usuario_autoriza['id_departamento']= 1) $departamento1 = "Sistemas"; ?> <?php echo $departamento1; ?></td>
<?php elseif(!$resultado['autorizado']): ?>
<th style="color:red;">No Autorizado Por:</th>
<td style="color:red;"><?=$resultado_usuario_autoriza['personaNombre']?> <?=$resultado_usuario_autoriza['apellido']?></td>
<?php endif; ?>
</tr>
<?php else: ?>
<tr>
<th>Autorizado Por:</th>
<td>Sin Autorizar</td>
</tr>
<?php endif; ?>
Here in the last image I show what I set when authorizing or un-authorizing the request.