문제

I have question about the other options... i have form like this...

<form action="edit.php" method="post">
.
.
.
.
<button class="btn btn-success"  name="submit_mult" type="submit">Edit</button>
</form>

I have another button called (delete) inside of above form in same page that will take action to delete.php page.

But the delete button is need to action to delete.php, but is already used up with action="edit.php" see above codes

How can i solve that to make both works!

AM

도움이 되었습니까?

해결책

You can use the formaction attribute on the button:

<button type="submit" formaction="delete.php">Delete</button>

This overrides the action attribute of the form when you click on that button.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top