My PHP html file includes a header include, a form, and a footer include. After
the user submits their information I want to replace the form part of the page
with a thank you note.
All the code for processing the form is in another file called submitsite.php,
at the bottom of which I echo "Thank you".
This is in the html file:
<?php include 'head.php' ?>
<?php if(!isset($_POST[$action])){ ?>
<input name="action" type="hidden" value="nomatter">
<table width="600" border="0" cellspacing="0" cellpadding="0">
<tr>
<td><form action="submitsite.php" method="post">
textboxes etc....
</table>
</form>
<?php } ?>
<?php include 'foot.php' ?>
After the user submits the form they are redirected to submitsite.php and see
"Thank you" without the header and footer.
How do I redirect back to the original page, so they see the same URL, header,
and footer, but with the form replaced with "Thank you"?
Thanks for your help.