I'm trying to use the <SCRIPT FOR = object EVENT = oncontextmenu> construct in IE.
Now you can specify <body oncontextmenu="myfunction()"> in HTML and the MSDN Link seems to me to imply that oncontextmenu is an event associated with the body object so naively I assumed
<SCRIPT FOR = document.body EVENT = oncontextmenu> would work! Does it %&*"! you have to use <SCRIPT FOR = document EVENT = oncontextmenu>
Similarly you can specify onunload in an HTML <BODY> tag but you have to use <SCRIPT FOR = window EVENT = onunload> to get it to work!!! I know one is a tag and the other a DOM object but I expected some sort of correlation.
Am I missing a piece of wondrous logic somewhere, how do I work out which DOM object I should use, i.e the one that initiates the event/gets the event bubbled to it???