I have a form and I would like the ACTION field to be different depending on the button pressed.
For instance the form might get processed by different PHP files if I press button A or button B.
How can I do this?
Thanks!
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
In your buttons you can just set the form’s action, using it’s
formproperty, for example on button a:On the other:
You can rig this up externally, like this:
Or if you’re using a library like jQuery: