I am trying to submit the login on pressing the Enter key, earlier everything was under a form tag so it would work on pressing the Enter key. But now it won't, could someone please give me a fix for this.
HTML:
Please Sign In
I am trying to submit the login on pressing the Enter key, earlier everything was under a form tag so it would work on pressing the Enter key. But now it won't, could someone please give me a fix for this.
HTML:
Please Sign In
Answer
Did you try to put a form tag arround it and bind an eventlistener to it:
document.querySelector('.myForm').addEventListener('submit', function(e) {
e.preventDefault();
// do your put request here
}
Laptop was acting really weird, and copy and seek times were really slow, so I decided to scan the hard drive surface. I have a couple hundr...
No comments:
Post a Comment