How to submit additional variables alongside form submission?
forms, html, php
Solution
You can use a hidden form field in your form:
<input type="hidden" name="step" value="2">
Problem
I have an HTML form that works properly and stores all variables ('firstname', 'lastname', etc.) in the `GET` array. At the time of form submission, I need to pass an additional variable in the `GET` array to let the PHP controller know to display the next set of prompts. Something simple like `step=2`. What I tried doing was setting the form action to `?step=2` as well as `?step=2&`. But, no matter what I try, the form's variables are all that show up in the URL. What am I doing wrong? Is this even possible?