I have a form which has a few text boxes, and two submit buttons. When a text box is selected, and I press Enter
, the first submit button is triggered. However, this is not the button that should be pressed at that time. How can I make it so that when the Enter
button is pressed, the second submit button (or at least, the last occurrence of the submit button) clicked?
I have an implementation of this currently using JavaScript, but I'm hoping there is a native option for it.