Have you looked at our double opt in tutorial on the data bridge support page:
data-bridge/
i believe this is what you are trying to accomplish.
the unsubscribe link should pass the users ID from the users table as a URL variable.
unsubscripbe.php?userID=1
you can use the URL variable to perform the update to unsubscribe them.