Currently the value in rented is a 0. If the box is checked I want the value to be 1 when submit button is clicked. Not sure how to go about the update process page.

<?php

mysql_connect("localhost","user","password");
mysql_select_db("listing");
$result2 = mysql_query("SELECT *
FROM available
JOIN land
ON available.building = land.building
WHERE land.landlord = '$landlordselect'
ORDER by available.price ASC");

echo "<table border='1'>
<tr>
<th>Building</th>
<th>Apartment #</th>
<th>Price</th>
<th># of Bedrooms</th>
<th>Move in</th>
<th>Rented</th>
</tr>";
while($row = mysql_fetch_array($result2))
{
echo "<tr>";
echo "<td>" . $row['building'] . "</td>";
echo "<td>" . $row['apt'] . "</td>";
?>
<form action="processpage.php" method="post">
<td><input name="uprice[]" type="text" size="5" value="<?php echo( htmlspecialchars( $row['price'] ) ); ?>" /> </td>
<?php
echo "<td>" . $row['bedroom'] . "</td>";
echo "<td>" . $row['movein'] . "</td>"; ?>
<td><input type="checkbox" name="rent[]" value="yes"></td>
<?php
echo "</tr>";
}
echo "</table>";
?>
<p><input type="submit" value="Update"><p>
</form>
<?php
mysql_close();
?>