hi,
in your html code, inside the form tag, there is the action parameter, where you put the url of the page that's opened when the user clicks the submit button.
This page can both be the page that you want to show, and the page where you have the code that updates the database.
Or this page simply updates the database and then redirects the user to that page using header
header ("Location: some_page.php");