Why does <body id="body" onkeypress="return SomeFunc(event)"> work but document.getElementById("body").onkeypress=SomeFunc; not work??? Every google search comes up with onkeypress as part of the XHTML, and I would prefer to avoid having to embed it in there like that.