I have a form which sends the user to a different form incase they don't complete it to go back to the form and complete anything that was missed. Now unless the user presses the browser back button the page is loaded fresh which mean any data gets lost.
Pretty much when they come back to the previous page, anything they already filled in should stay intact.
I have the following two pages:
Page 1:
<?PHP
echo "<a href='page2.php'>NEXT</a>";
echo "<input type=text size=25 name=txt />";
?>
Page 2:
<?php
$refer = $_SERVER['HTTP_REFERER'];
$lastlink = "<a href='$refer'>BACK</a>";
echo $lastlink;
?>
On page two if i click BACK to come back to page 1, anything entered in page 1 will be lost which I do not want. How do I work around it without using Javascript? with Javascript? I know in javascript I can use
<a href="javascript:history.go(-1);">BACK</a>
But is there another way?