Qwerty Shifter (keyboard event handling)

Qwerty Shifter (keyboard event handling)

Hi I am trying to develop a

Qwerty Shifter

http://www.cross-browser.com/toys/qwertyshifter.html

by handling keyboard events.

 

I want to display a textbox and as user type any text it changes at once means as user types "a" it display "s"

"b" changes "n"

 

for internet explorer I have script BUT want a cross browser solution for this

 

function InputEventKeyPress(event){

 

 

 

            window.event.keyCode  = shifter (window.event.keyCode);

 

 

 

} //Key press

 

 

function shifter (keyAscii)

{

switch (keyAscii){

//CAPITAL LETTERS A - Z

case 65 : return 83; break; //A

case 66 : return 78; break; //B

case 67 : return 86 ; break; //C

}

}