J
Jacob Friis Larsen
Courtesy RobB I have the below so a user can use my shortcut keys in
forms, but if a user using Mozilla Firefox press ' to search for links,
my shortcut keys are activated if used. This also happens in Gmail.
Is this a bug?
document.onkeydown = function (e) {
var tgt = null;
if ((e = e || window.event) //get event object
&& (tgt = e.target || e.srcElement) //get trigger element
&& tgt.type //has 'type' property?
&& /text/.test(tgt.type)) //'text' or 'textarea'?
return true; //end processing
}
Thanks,
Jacob
forms, but if a user using Mozilla Firefox press ' to search for links,
my shortcut keys are activated if used. This also happens in Gmail.
Is this a bug?
document.onkeydown = function (e) {
var tgt = null;
if ((e = e || window.event) //get event object
&& (tgt = e.target || e.srcElement) //get trigger element
&& tgt.type //has 'type' property?
&& /text/.test(tgt.type)) //'text' or 'textarea'?
return true; //end processing
}
Thanks,
Jacob