Re: Validation: Problems with header(Location) in PHP

From: Date: Wed, 24 Sep 2003 22:58:31 +0000
Subject: Re: Validation: Problems with header(Location) in PHP
References: 1 2  Groups: php.general 
Request: Send a blank email to php-general+get-163651@lists.php.net to get a copy of this message
Hi Jason, Thank you for answering me. I am sending the code that you requested. I've shotened it for brevity. The idea is that I am going to make the validation in the (2nd) "newaccount2.php" file which is the confirmation file. If everything is OK I will just print the correct filled-in data. Otherwise I would like to redirect the users back to the previous page ("newaccount1.php"). <html> <title>This is newaccount1.php</title> <form name="form1" method="post" action="newaccount2.php"> <input name="Dosubmit" type="hidden" value="0" id="Hidden1"> Name <input type="text" name="Name" id="name" size="30" /><br /> Email <input type="text" name="Email" size="30" /><br /> Street Address <input type="text" name="Address" id="Address" size="30" /><br /> <input type="submit" value="Next" /> </form> </body> </html> Btw, for the functionality I want to achieve is it better that I submit the data to the same form ($php_self)? It would probably be better as I'll avoid redirecting to and back all the time. I've surfed a little but found no ellegant validation solution so far. Thank you very much, Martin.

« previous php.general (#163651) next »