PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!
I have an HTML form that has input fields and a submit button. Upon submission I would like to first check that all fields have been filled in, and if so, the load the next php file. The problem is that I have a function setup to check my fields after submission so I need to set my form's action to my first php page. If all fields are filled in, then I need to pass variables to my next script. How can I this be done through php (or javascript)?
I rewrote your code a bit, included a better error handling method, and set it up to transfer the variables via GET (since I assume you don't know how to use sessions yet).
Thank you for your help, I appreciate it. I assume you mean, I need to use '$_GET' on my second page to retrieve the variables from the first since you are using '$_POST' in teh code? I
I would like to add a 'back' button and save the information through the pages so maybe I need to look further into session variables.