faqts : Computers : Programming : Languages : JavaScript : Event handling

+ Search
Add Entry AlertManage Folder Edit Entry Add page to http://del.icio.us/
Did You Find This Entry Useful?

7 of 9 people (78%) answered Yes
Recently 4 of 6 people (67%) answered Yes

Entry

i have a contextmenu that can be disabled when clicking on the specific frame how do i do the same by clicking on other frames instead

Mar 1st, 2001 08:29
jsWalter, chin min,


As of NN 4.5 and IE 5.5...
This is a document level event in IE, you can only trap it in the 
document. This means you need to include that piece of JS code in EACH 
document you want the contextmenu to be disabled.
My version disables it, but only in 'context', meaning if you are in a 
text box or a textarea object, the contextmenu works, if you are 
anywhere else, it doesn't.
In NN, this can be a window level event, meaning you CAN trap it at the 
top level so none of your frames will have a contextmenu.
Walter