So i have three pages of php:
- page 1: user enters their information, blah blah blah.. let's assume they enter their registration information. The user clicks on submit button, and the information is sent using POST method to page 2.
- page 2: the $_POST values from page 1 is processed. Error checking, verification, and all that. If an error occured, the user is sent back to page 1, but we want to keep the values they typed intact. That means, if they entered their birthday on page 1, we found out that the birthday is invalid on page 2, we want to send them back to page 1 with their incorrect birthday value still filled in the appropriate <input type="text">
- still page 2: if there is no error, we want to automatically forward all the $_POST values to page 3 to be processed even further.
- page 3: get the $_POST value from page2, which was obtained from page1 when the user hit the submit button.
The question would be: how to accomplish that?
The catch: The user should not be doing anything on page 2. They are not required to click on another submit button to pass the $_POST values to the next page. All they do is click submit on page 1, and our PHP script automatically process the $_POST values on page 2, and forward the $_POST values to be used again on page 3.
Is there an easy way of doing this? Or do we have to use a pop-up of some sort? Javascript? Cookies? Etc?
Any suggestions so that the user don't have to do anything on page 2?
Thanks, and hopefully it's not too confusing....
- page 1: user enters their information, blah blah blah.. let's assume they enter their registration information. The user clicks on submit button, and the information is sent using POST method to page 2.
- page 2: the $_POST values from page 1 is processed. Error checking, verification, and all that. If an error occured, the user is sent back to page 1, but we want to keep the values they typed intact. That means, if they entered their birthday on page 1, we found out that the birthday is invalid on page 2, we want to send them back to page 1 with their incorrect birthday value still filled in the appropriate <input type="text">
- still page 2: if there is no error, we want to automatically forward all the $_POST values to page 3 to be processed even further.
- page 3: get the $_POST value from page2, which was obtained from page1 when the user hit the submit button.
The question would be: how to accomplish that?
The catch: The user should not be doing anything on page 2. They are not required to click on another submit button to pass the $_POST values to the next page. All they do is click submit on page 1, and our PHP script automatically process the $_POST values on page 2, and forward the $_POST values to be used again on page 3.
Is there an easy way of doing this? Or do we have to use a pop-up of some sort? Javascript? Cookies? Etc?
Any suggestions so that the user don't have to do anything on page 2?
Thanks, and hopefully it's not too confusing....