:: Forum >>
Halt Backspace key press on IE
Hi,
Having problem with Backspace key. When user hit the Backspace key, my code should just display message and stop the action. But, instead the browser go to previous page (I think this is standard behavior for backspace).
Following is my code:-
obj.onKeyBackspace = function(event){
alert("Backspace key pressed");
return 1;
}
Any help, please?
TIA
lcs
Wednesday, September 27, 2006
Any help?
thanks
lcs
Thursday, September 28, 2006
Ics,
try this.
document.onkeydown = haltBackspace;
function haltBackspace() {
if (window.event && window.event.keyCode == 8) {
return false;
}
}
raymone
Thursday, September 28, 2006
It works! thanks.
lcs
Thursday, September 28, 2006
This topic is archived.
Back to support forum
Forum search