[web] Using the input tag to collect information.
Hi,
When I create a button using
<input type="submit" name="StepButton" value="Add Step" />
The button has the words "Add Step" on it, and it sends a parameter "StepButton=Add Step" to my php script.
Is there anyway to send what I need from the button?
ie. I want the button to send the parameters "StepButton=132214" but still display "Add Step" on the actual button.
Sorry if that wasn't clear.
Thanks a lot for your help
-Cuppo
Just add a hidden field to your form to send additional parameters, that's what they're for.
<form method="post" action="script.php"> <input type="hidden" name="step" value="132214"/> <input type="submit" name="StepButton" value="Add Step" /></form>
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement