Are users complaining that every time they click the 'Enter' key on the keyboard, it automatically submits a form. Use this short JavaScript function to disable the enter key on the Web.
var NS = (window.Event) ? 1 : 0;
function checkKey(e) {
var code = (NS) ? e.which : event.keyCode;
if (code == "13"){
return false; }
}
document.onkeypress = checkKey;
Requires Free Membership to View
Register today to access targeted resources from our editorial writers and independent industry experts focused on Lotus Domino, Notes, Workplace and other related technologies.
This was first published in February 2001