I am creating a kiosk where people can register for sessions. Each session time slot is displayed in a button with the number of seats remaining. When the capacity reaches 0, text displays under the time slot on the button that says "no seats remaining".
How can i disable the button based on a value in my PHP array, so people are unable to click it?
<button type="submit" name="DS1" value="1">
<h4>10:30 - 11:15</h4>
<h5><?php if ($result[0]['capacity'] > "0") {
echo $result[0]['capacity'];
echo " Seats Remaining";
} else {
echo "This Session is Full!";
} ?></h5>
</button>