i have a simple form with two buttons, and i want to trigger these buttons with keyboard keys in combination with Alt key.
for example Alt + P (uppercase) should trigger button 1 and
Alt + p (lowercase) should trigger button 2
Browser: IE 8.0
here is the code…
<!DOCTYPE HTML PUBLIC “-//W3C//DTD HTML 4.01 Transitional//EN” “http://www.w3.org/TR/html4/loose.dtd”>
<html>
<head>
<title> Alt KeyStrokes </title>
<body>
<form method=“post” action=“”>
<button onclick=“alert(‘Big P’);” accesskey=“P” > <u>P</u> </button>
<button onclick="alert('Small P');" accesskey="p" > <u>p</u> </button>
</form>
</body>
</html>
here the behavior is strange, when i press Alt+P in keyboard uppercase button is triggered rather than lower case and when i press Alt+Shift+P in keyboard lowercase button is triggered rather than upper case…how to overcome this problem…
need suggestions