[thelist] trapping keyboard combo on Mac OSX

liorean liorean at f2o.org
Thu Feb 19 11:02:01 CST 2004


Scott Blanchard wrote:
> I tried your code change, to no avail. I still cannot seem to trap the
> keyboard combo of CTRL+8 on mac osx in any web browser.

I just tested in on a number of browsers, using 
<http://www.din.or.jp/~hagi3/JavaScript/JSTips/Mozilla/Samples/KeyEvent.htm>.



Using Mozilla Firebird 0.7.1, that DOM Samples page gives ctrlKey=true, 
keyCode=88, which=88, charCode=0 on keydown and keyup. On keypress, 
ctrlKey=true, keyCode is 0, which=56 and charCode=56.

Using Apple Safari 1.2, ctrlKey=true, keyCode=56, charCode=56, which=56 
on keydown, keyup, keypress.

Using Microsoft Internet Explorer 5.2.3 for Mac, ctrlKey=true, 
keyCode=56 on keyup, keydown, keypress.

Opera 6.03 does the same as Microsoft Internet Explorer 5.2.3 for Mac.



Only Microsoft Internet Explorer 5.2.3 for Mac triggers on pressing just 
the ctrl key, the others demand ctrl key to be in combination with 
another key.
-- 
David "liorean" Andersson

ViewStyles, ViewScripts, SwitchStyles and GraphicsInfo bookmarklets:
<http://liorean.web-graphics.com/>
Hangouts:
<http://codingforums.com/> <http://yourmusicforums.com/>


More information about the thelist mailing list