php two self submitting forms on one page

Ryeppiavo

New Member
I have a webpage form that submits to itself to carry out php action. I want to add a second form to this same webpage that is capable of self submit as well but I am not having any luck finding a working solution for my setup. Here is what my webpage looks like.First, it checks to see if the page has already been submitted, and if it has, it redirects elsewhere.\[code\]if($_SERVER['REQUEST_METHOD'] == "POST") {header("Location: viewcustomers.php");}\[/code\]Next, the form itself.\[code\]<form id="addCustomer" method="POST" action=""> ..stuff.. </form>\[/code\]Then, finally my form action.\[code\]if('POST' == $_SERVER['REQUEST_METHOD']) {..phpstuff..}\[/code\]How could I adjust this form action (or add another) to differentiate between two different forms? Thanks.
 
Back
Top