| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
#1
|
|||
|
|||
|
I was wondering how to make keyboard keys correspond to certain links on a webpage. For example if there was a "maze" with the folowing screen:
North West | East South (Imagine North, South, West, and East as links taking you to their respective direction) How would I program it so that if I pressed the up arrow on my keyboard it would take me north, left arrow would take me west, etc. |
|
#2
|
||||
|
||||
|
Look into using Javascript to capture when the arrows are pressed down.
You can use event.keyCode which returns the unicode value. The values are: ← left arrow keyCode value: 37 ↑ up arrow keyCode value: 38 → right arrow keyCode value: 39 ↓ down arrow keyCode value: 40 -------------------------------------------------------------------------------- Cast your vote in this form validation poll: http://forums.aspfree.com/t34569/s.html |
![]() |
| Viewing: ASP Free Forums > Programming > Code Bank > I need some serious coding help |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|