sepoto Posted May 13, 2011 Share Posted May 13, 2011 I am trying to come up with a system where I can have multiple input buttons on a form and detect which input button was pressed once the form is processed. <form action="displaydata.php" method="post"><input type = 'Submit' Name = 'submit01' Value = 'get recordset'><input type = 'Submit' Name = 'submit02' Value = 'auto weed recordset'></form> displaydata.php: <?php /* Is it possible to detect in here which input button was pressed? */?> Thank you. Link to comment Share on other sites More sharing options...
birbal Posted May 13, 2011 Share Posted May 13, 2011 You can check for particular button set or not to determine which button has been pressed. if(isset($_POST['submit01']))//submit01 pressed You can also check for button value also Link to comment Share on other sites More sharing options...
sepoto Posted May 13, 2011 Author Share Posted May 13, 2011 You can check for particular button set or not to determine which button has been pressed.if(isset($_POST['submit01']))//submit01 pressed You can also check for button value also I see the use of isset() again is my solution. What a handy function. Thank you. Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.