So I am having an issue in Firefox with the onkeydown event for an image button. I don't want the button action to fire until they let up off the button. So this works great in both IE and Chrome. I cannot figure out why it doesn't work in Firefox(20.0.1).
Here is the image button code:
<asp:ImageButton ID="btnButton1" ImageUrl="/images/target.png" runat="server"
Height="75" Width="75" onkeydown="return false;" onkeyup="ButtonClick()" />
So the onkeyup seems to work perfect in all browsers, but the onkeydown does not want to work in Firefox and I cannot figure it out. Any help would be greatly appreciated.
I don't know if it will help, but I will post my JavaScript function for onkeyup as well:
function ButtonClick() {
document.getElementById('<%=btnButton1.ClientID %>').click();
return true;
}
...
Go to the complete details ...