Hi i wanted to make registration form.
but i don’t know how to return data if the data failed after i click submit.
the data became empty so i wanted to restore before user click submit.
<form id="form1" name="form1" method="post" action="doregister.php">
<input type="text" name="txtnama" id="txtnama" />
<textarea name="txtalamat" id="txtalamat" cols="30" rows="5"></textarea>
<input type="submit" name="txtsubmit" id="txtsubmit" value="Submit" />
<input type="reset" name="txtreset" id="txtreset" value="Reset" />
</form>
here the picture:
http://tinypic.com/r/160sopk/5
Thanks in advance for any help, and I’m really sorry if this has been asked before.
You have to put back the posted values:
If
doregister.phpis another page, you should check the values in the current page then redirect todoregister.phpif ok.