What I do is set the form action to the same page as the form, and use a hidden form field to see if it has been submitted.
if I have a field called name, I do this:
<input type=text name='name' value='<?=@htmlspecialchars($uname)?>'>
So if there is a missing variable, then I'll unset the hidden variable that'll action the info, so it'll redisplay the form. And then I also set all the good variables to the same name with a u in from for 'u'pdate!
Anyways, there's a multitude of ways of doing it, you just need to put a variable for the value in each field, and find a way to manipulate it!

