I would like to assign type=submit and type=button in one button like
<button type="button" type="submit></button>
I need to use the type=submit so that I can put all the answers in my database and type=button to bring them to another modal. That's why I'd like to use both types in one button. I hope you can help me or teach some alternatives. Thank you
<form class="mt-1" method="POST">
<div class="form-group d-flex justify-content-center">
<input type="text" class="form-control w-100" placeholder="First Name" name="firstName">
</div>
<button type="submit" class="btn btn-primary" data-bs-toggle="modal" data-bs-target="#confirmModal" >Next</button>
</form>
<div class="modal fade" id="confirmModal" >
<div class="modal-dialog">
<div class="modal-content">
<div class="modal-body">
<p>Your form has been submitted</p>
</div>
<div class="modal-footer">
<button type="button" class="btn btn-primary " data-bs-dismiss="modal">Confirm</button>
</div>
</div>
</div>
</div>