I wrote a typing tutor a while ago and this is a somewhat common pitfall, to manually handle characters by pulling key codes. Instead you should let the O/S tell you which character was typed (and also check key codes, for things like backspace) which then handles different layouts / locales etc.
Edit: Ok, it works in Chrome - so it's not working for me in Firefox 14.0.1 on OS X Lion.
Now that I can use it, I love it, but I have one request - I'd like to be able to go back and see my stats, please!
KeyboardJS has a basic locales mapping: https://github.com/RobertWHurst/KeyboardJS , Unfortunately it appears to only have en_US at the momment though
This on Firefox 14, Chromium 18, Opera 12, for Linux Mint.
Otherwise, this is great!
EDIT: Does it read the key-code, instead of the character? Is it not possible to listen for the character input?
It occurs both in Chrome and Firefox.
It wasn't even enough to press the corresponding button where semicolon is placed on English layout, I had to actually switch keyboard-layout and then press the correct button to get past it.
In windows, I made my own keyboard layout in Microsoft Keyboard Layout Creator (so that I could switch the symbols to UK but also so I could add some dead keys to AltGr for various unicode symbols). I did "fix" the VK codes for the alphabethic characters, but I guess the symbols are still using whatever the key is assigned by default and I guess JS (at least in Chrome on Windows 7) checks the key code reported by the OS, rather than the value reported by the OS.
On Arch I use the GB colemak layout that came with the distro and I guess it sets all the key codes correctly to where all the symbols are...