I have a MySql database with the var 'mls', which either has an entry of 0 or 1.
I am trying to use an If statement to display text depending on the mls var.
The data is being pulled from the datbase ok becasue I can use an 'echo' to dispaly the entry of the 'mls'. The problem is it is just going straight to the else statement and showing the 'else' data, here is the code...
<? echo ucwords($res['mls']); ?>
<? if ($res['mls']) == 0)){
echo $lang['rental'];
}else
echo $lang['purchase'];
?>
Any help would be great.
ucword-ing a number?