echo "<td>" . $row['Rp'] . "</td>"; echo "<td>" . $row['Sp'] . "</td>";
In the above PHP snippet, I'd like to change the data output with fixed values like "1" for Rp, "2" for Sp. Sometimes there are no data output, in these cases, it should be blank. How can I do this with php? (if there is an easy way). Thanks.
Note: I don't want to use a function in query for this.