I have the following:
$(top.document).ready(function() {

alert("Getting in ");

$(top.main.document).bind('click keydown resize dblclick', detectEvent);

which works. WHen I chenge $(top.main.document).bind into $(top.document).bind.... it will not work. Main is the one frame out of 4.
What I wanted to check frameset as whole to detect some events. Yes, I can do that if I include each frame at the bottom of that instructions.

Anyway, with menu and on page buttons I could load a new page in frame "main" by doing:

top.main.location.href = URL;

However, with new URL page in "main" frame, the detection of events suddenly stopped. Why is that?What I am doing wrong?