Two submit buttons in one form
Solution 1: Give each input a different value and keep the same name: <input type=”submit” name=”action” value=”Update” /> <input type=”submit” name=”action” value=”Delete” /> Then in the code check to see which was triggered: if ($_POST[‘action’] == ‘Update’) { //action for update here } else if ($_POST[‘action’] == ‘Delete’) { //action for delete } else { … Read more