Illustrates a technique that can be used to allow the ENTER key to navigate between fields on a web page.
Do you users complain about having to use the TAB key to move from field to field on your web page? The code below contains an illustration of a technique that will convert a Carriage Return to a TAB character. Naturally, you can change the pseudo-TAB key by modifying the ASCII value that is part of the test.
<SCRIPT language="javascript">
<!--
function TranslateKey(keypress) {
if ( event.keyCode == 13) { event.keyCode = 9; }
}
window.document.onkeydown = TranslateKey ;
//-->
</SCRIPT>
Comments