prepare($sql);
$stmt->bind_param("s", $AccID);
$stmt->execute();
// Get the result set
$result = $stmt->get_result();
// Check if there's a matching user
if ($result->num_rows > 0) {
// Update password if user exists
$update_sql = "UPDATE renter SET Renter_Pass = ? WHERE Renter_ID = ?";
$update_stmt = $conn->prepare($update_sql);
$update_stmt->bind_param("ss", $AccNPass, $AccID);
if ($update_stmt->execute()) {
// Password updated successfully
echo "";
echo "";
exit();
}
}
else {
echo "";
echo "";
exit();
}
}
?>