I'm fairly new to PHP but why not just read the data into the "thank you" page from the database if it's already there. As far as the id number for the user you should be able to use mysql_insert_id() and then just tack that onto your redirect. For instance:
if($validated) {
// insert queries here
if($successful) {
header("Location: thankyou.php?id=".mysql_insert_id());
die();
}
}
Untested. I plan on using this myself eventually. You see, originally I had this huge $_SESSION array that contained all the data from all the pages that preceded the "thank you for registering" page. Now I just use the database on every page. The first page will be inserts and subsequent pages will be updates:
.. where id={$_GET['id']}
But your definitely in the right place to find help. So many people have helped me here I just wanted to pitch in. 🙂