I am tring to have a user click the submit buttion and the status of that row/room will become closed and the user can reserve more than 1 room at a time
<html>
<head>
</head>
<body>
<?php
//include database configuration
include 'config_open_db.php';
//selecting records
$sql="select RoomNumber, Type, Cost, Status from Rooms";
//query the database
$rs=mysql_query($sql) or die($sql.">>".mysql_error());
//count how many records found
$num=mysql_num_rows($rs);
if($num>0){ //check if more than 0 record found
echo "<table border='1'>";//start table
//creating table heading
echo "<tr>";
echo "<th>RoomNumber</th>";
echo "<th>Type Of Room</th>";
echo "<th>Cost</th>";
echo "<th>Status</th>";
echo "</tr>";
//retrieve our table contents
while($row=mysql_fetch_array($rs)){
//extract row
extract($row);
//creating new table row per record
echo "<tr>";
echo "<td>{$RoomNumber}</td>";
echo "<td>{$Type}</td>";
echo "<td>{$Cost}</td>";
echo "<td>{$Status}</td>";
echo "<td>" . '<input type="submit" name="submit" value=" Reserve">' . "</td>";
echo "</tr>";
}
echo "</table>";//end table
}else{ //if no records found
echo "No records found.";
}
?>
</body>
</html>