Answers for "on enter pressed textbox"

1

on enter press button

<input onkeyup="if(event.keyCode===13){submit.click()}"><button id="submit">submit</button>
Posted by: Guest on September-24-2021
1

How to trigger button using enter keyword in an input box?

document.getElementById("pw")
    .addEventListener("keyup", function(event) {
    event.preventDefault();
    if (event.keyCode === 13) {
        document.getElementById("myButton").click();
    }
});

function buttonCode()
{
  alert("Button code executed.");
}
Posted by: Guest on February-05-2022

Code answers related to "on enter pressed textbox"

Code answers related to "Assembly"

Browse Popular Code Answers by Language